diff options
| author | Michael Williamson <mike@zwobble.org> | 2014-04-10 13:46:57 +0100 |
|---|---|---|
| committer | Michael Williamson <mike@zwobble.org> | 2014-04-10 13:46:57 +0100 |
| commit | 83ac75808b14862531b046f51f90014d7dea621e (patch) | |
| tree | c5a08546bf69da3809bbb633c9395e58428e9d03 /tests | |
| parent | 0c131afbe82cedeef9815d11428414d6dc663ae7 (diff) | |
Fix error when a zip file cannot be opened
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/unzip.tests.js | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/tests/unzip.tests.js b/tests/unzip.tests.js new file mode 100644 index 0000000..95aa26f --- /dev/null +++ b/tests/unzip.tests.js @@ -0,0 +1,14 @@ +var assert = require("assert"); + +var test = require("./testing").test; +var unzip = require("../lib/unzip"); + +describe("unzip", function() { + test("unzip fails if given empty object", function() { + return unzip.openZip({}).then(function() { + assert.ok(false, "Expected failure"); + }, function(error) { + assert.equal("Could not find file in options", error.message); + }); + }); +}); |
