Browse Source

beef up test

legacy-quote-reserved-properties
Rich-Harris 8 years ago
parent
commit
f143b01c62
  1. 4
      test/function/if-statement-with-assignment/main.js
  2. 4
      test/function/if-statement-with-update/main.js

4
test/function/if-statement-with-assignment/main.js

@ -1,4 +1,6 @@
var result = 0; var result = 0;
if ( Math.random() <= 1 ) result += 1; if ( Math.random() <= 1 ) {
if ( Math.random() <= 1 ) result += 1;
}
assert.equal( result, 1 ); assert.equal( result, 1 );

4
test/function/if-statement-with-update/main.js

@ -1,4 +1,6 @@
var result = 0; var result = 0;
if ( Math.random() <= 1 ) ++result; if ( Math.random() <= 1 ) {
if ( Math.random() <= 1 ) ++result;
}
assert.equal( result, 1 ); assert.equal( result, 1 );

Loading…
Cancel
Save