mirror of
https://github.com/rails/execjs
synced 2023-03-27 23:21:20 -04:00
Ensure console is undefined
This commit is contained in:
parent
f061eae84e
commit
ac113e62ab
1 changed files with 4 additions and 0 deletions
|
@ -139,6 +139,10 @@ class TestExecJS < Test::Unit::TestCase
|
|||
assert ExecJS.eval("typeof require == 'undefined'")
|
||||
end
|
||||
|
||||
def test_console_is_undefined
|
||||
assert ExecJS.eval("typeof console == 'undefined'")
|
||||
end
|
||||
|
||||
def test_compile_large_scripts
|
||||
body = "var foo = 'bar';\n" * 100_000
|
||||
assert ExecJS.exec("function foo() {\n#{body}\n};\nreturn true")
|
||||
|
|
Loading…
Reference in a new issue