From 7c0a44529ca0d536bcc097077e88051188606ab6 Mon Sep 17 00:00:00 2001 From: brodan Date: Mon, 4 Apr 2022 18:17:20 -0400 Subject: [PATCH] Add missing file name to 'Input file is missing' error message --- package.json | 3 ++- src/common.cc | 2 +- test/unit/io.js | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/package.json b/package.json index ec24a374c..cdc16a7c9 100644 --- a/package.json +++ b/package.json @@ -81,7 +81,8 @@ "Taneli Vatanen ", "Joris Dugué ", "Chris Banks ", - "Ompal Singh " + "Ompal Singh ", + "Brodan file.substr(0, 8) + "...')?"); } - throw vips::VError("Input file is missing"); + throw vips::VError("Input file is missing: " + descriptor->file); } if (imageType != ImageType::UNKNOWN) { try { diff --git a/test/unit/io.js b/test/unit/io.js index c264644df..dc6004aaf 100644 --- a/test/unit/io.js +++ b/test/unit/io.js @@ -457,7 +457,7 @@ describe('Input/output', function () { done(); }).catch(function (err) { assert(err instanceof Error); - assert.strictEqual('Input file is missing', err.message); + assert.strictEqual('Input file is missing: does-not-exist', err.message); done(); }); });