diff options
Diffstat (limited to 'js/src/jit-test/tests/environments/delete-global-var.js')
-rw-r--r-- | js/src/jit-test/tests/environments/delete-global-var.js | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/js/src/jit-test/tests/environments/delete-global-var.js b/js/src/jit-test/tests/environments/delete-global-var.js new file mode 100644 index 0000000000..03b128affe --- /dev/null +++ b/js/src/jit-test/tests/environments/delete-global-var.js @@ -0,0 +1,13 @@ +let assert = assertEq; + +this.x = "OK"; +this.y = "FAIL"; + +for (let i = 0; i < 50; i++) { + assert(x, "OK"); + if (i === 40) { + this.x = "FAIL"; + delete this.x; + this.x = "OK"; + } +} |