Skip to content
This repository has been archived by the owner on Dec 3, 2023. It is now read-only.

Commit

Permalink
error checking
Browse files Browse the repository at this point in the history
  • Loading branch information
fent committed Jun 12, 2013
1 parent 8a3a87e commit 524416b
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions test/download.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ vows.describe('download').addBatch({
},

'data returned': function(err, progress, data) {
if (err) throw err;

assert.isObject(progress);
assert.include(progress, 'percent');
assert.isString(progress.percent);
Expand All @@ -51,6 +53,8 @@ vows.describe('download').addBatch({
},

'file was downloaded': function(err, progress, data) {
if (err) throw err;

process.nextTick(function() {
// Delete file after each test.
fs.unlink(filepath);
Expand Down

0 comments on commit 524416b

Please sign in to comment.