Skip to content

Commit

Permalink
1) add final tally to console
Browse files Browse the repository at this point in the history
2) Fix octal escape sequence
  • Loading branch information
angus-c committed May 2, 2011
1 parent 9f955ab commit 7833a4e
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/tests.js
Expand Up @@ -63,8 +63,11 @@
}

function finishAll() {
var result = ["","(", testsPassed, "out of", totalTests, "tests passed", ")"].join(' ');
if (mode == HTML_MODE) {
banner.innerHTML += ["","(", testsPassed, "out of", totalTests, "tests passed", ")"].join(' ');
banner.innerHTML += result;
} else if (mode == CONSOLE_MODE) {
console.log(result);
}
}

Expand All @@ -80,7 +83,7 @@

// A conforming implementation, when processing strict mode code (see 10.1.1), may not
//extend the syntax of EscapeSequence to include OctalEscapeSequence as described in B.1.2.
testException("no octal escape sequence", '"\012"', SyntaxError);
testException("no octal escape sequence", '"\\012"', SyntaxError);

// Assignment to an undeclared identifier or otherwise unresolvable reference does not
//create a property in the global object. When a simple assignment occurs within strict
Expand Down

0 comments on commit 7833a4e

Please sign in to comment.