Skip to content

Commit

Permalink
test syntax error
Browse files Browse the repository at this point in the history
  • Loading branch information
alongubkin committed Nov 13, 2014
1 parent 38d9d66 commit 96b5129
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion test/spider_test.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,13 @@ function generateErrorTest(code, expectedErrors) {
delete error.loc;

return error;
})).match(expectedErrors);
})).eql(expectedErrors);
};
}

describe('variable statement:', function () {
it('syntax error', generateErrorTest('var x = y^', [{ type: "SyntaxError" }]));

it('create variable',
generateTest('var a;', 'var a;'));

Expand Down

0 comments on commit 96b5129

Please sign in to comment.