diff options
Diffstat (limited to 'ext/zip/tests/zip_entry_close.phpt')
-rw-r--r-- | ext/zip/tests/zip_entry_close.phpt | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/ext/zip/tests/zip_entry_close.phpt b/ext/zip/tests/zip_entry_close.phpt index 2f2581b2d0..f11f3112a9 100644 --- a/ext/zip/tests/zip_entry_close.phpt +++ b/ext/zip/tests/zip_entry_close.phpt @@ -10,14 +10,16 @@ $zip = zip_open(__DIR__."/test_procedural.zip"); $entry = zip_read($zip); echo "entry_open: "; var_dump(zip_entry_open($zip, $entry, "r")); echo "entry_close: "; var_dump(zip_entry_close($entry)); -echo "entry_close: "; var_dump(zip_entry_close($entry)); +try { + echo "entry_close: "; var_dump(zip_entry_close($entry)); +} catch (TypeError $e) { + echo $e->getMessage(), "\n"; +} zip_close($zip); ?> Done ---EXPECTF-- +--EXPECT-- entry_open: bool(true) entry_close: bool(true) -entry_close: -Warning: zip_entry_close(): supplied resource is not a valid Zip Entry resource in %s -bool(false) +entry_close: zip_entry_close(): supplied resource is not a valid Zip Entry resource Done |