Skip to content

Commit

Permalink
Improved perform test by being more explicit.
Browse files Browse the repository at this point in the history
Being more explicit about the server failing in one of the
.perform() tests, rather than it failing because of non-existing
fixture which was *truly* hard to debug / figure out...
  • Loading branch information
phillipj committed Sep 19, 2015
1 parent 4dc0786 commit aede7b4
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions test/perform-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,8 @@ describe('perform()', function() {
});

it('promise should fail when server responds with failure status code', function() {
return api.perform(PERFORM_URL).fail(function(err) {
server.fails();
return api.perform(PERFORM_URL).fail(function(err) {
expect(err).not.to.be(null);
});
});
Expand All @@ -37,4 +38,4 @@ describe('perform()', function() {
server.withoutContent();
return api.perform(PERFORM_URL);
});
});
});

0 comments on commit aede7b4

Please sign in to comment.