From 12e2cba1a2c33e3d709c6e1a4246ba236670c77f Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Fri, 26 Jun 2026 09:44:23 +0200 Subject: improve rpminfo errors test --- tests/006-rpminfo-errors.phpt | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'tests') diff --git a/tests/006-rpminfo-errors.phpt b/tests/006-rpminfo-errors.phpt index 007ed5c..bf3a5f6 100644 --- a/tests/006-rpminfo-errors.phpt +++ b/tests/006-rpminfo-errors.phpt @@ -7,8 +7,9 @@ Check for rpminfo function errors echo "+ PHP Warnings\n"; var_dump(rpminfo(__DIR__ . "/missing.rpm")); var_dump(rpminfo(__FILE__)); +var_dump(is_array(rpminfo(__DIR__ . "/bidon.rpm"))); -echo "\n+ PHP Warnings\n"; +echo "\n+ Error returned\n"; $error='xxx'; var_dump(rpminfo(__DIR__ . "/missing.rpm", true, $error), $error); @@ -26,8 +27,9 @@ NULL Warning: rpminfo(): Can't read '%s/tests/006-rpminfo-errors.php': Argument is not a RPM file in %s on line %d NULL +bool(true) -+ PHP Warnings ++ Error returned NULL string(%d) "Can't open '%s/tests/missing.rpm': No such file or directory" NULL -- cgit