Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
test: move assert to improve clarity
A test is run, and then the relevant assertion is put after a different
test. Place the assertion near the relevant thing it is testing for
clarity.
  • Loading branch information
Trott committed Apr 27, 2016
commit 0e05d3dccd095fd6afa6caa5f88d3ebdbb09373e
3 changes: 2 additions & 1 deletion test/parallel/test-assert.js
Original file line number Diff line number Diff line change
Expand Up @@ -394,12 +394,13 @@ try {
} catch (e) {
gotError = true;
}
assert.ok(gotError);


// GH-7178. Ensure reflexivity of deepEqual with `arguments` objects.
var args = (function() { return arguments; })();
a.throws(makeBlock(a.deepEqual, [], args));
a.throws(makeBlock(a.deepEqual, args, []));
assert.ok(gotError);


var circular = {y: 1};
Expand Down