Skip to content

Commit

Permalink
test: add toJSON tests [@jderuere]
Browse files Browse the repository at this point in the history
  • Loading branch information
rauchg committed Nov 18, 2015
1 parent b8b71d4 commit 1bf5347
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions test.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,12 @@ describe('has-binarydata', function(){
});

it('should work with an object that does not contain binary', function() {
var ob = {a: 'a', b: [], c: 1234};
var ob = {a: 'a', b: [], c: 1234, toJSON: '{\"a\": \"a\"}'};
assert(!hasBinary(ob));
});

it('should work with an object that contains a buffer', function() {
var ob = {a: 'a', b: new Buffer('abc'), c: 1234};
var ob = {a: 'a', b: new Buffer('abc'), c: 1234, toJSON: '{\"a\": \"a\"}'};
assert(hasBinary(ob));
});

Expand Down

0 comments on commit 1bf5347

Please sign in to comment.