[test] properly 'skip' test on JRuby
an early return still caused ensure to execute, setting JSON constant to `nil` for later tests!
This commit is contained in:
parent
f8d43e5370
commit
0089854fc5
Notes:
git
2020-09-25 17:29:12 +09:00
@ -49,7 +49,6 @@ EOT
|
|||||||
end
|
end
|
||||||
|
|
||||||
def test_remove_const_segv
|
def test_remove_const_segv
|
||||||
return if RUBY_ENGINE == 'jruby'
|
|
||||||
stress = GC.stress
|
stress = GC.stress
|
||||||
const = JSON::SAFE_STATE_PROTOTYPE.dup
|
const = JSON::SAFE_STATE_PROTOTYPE.dup
|
||||||
|
|
||||||
@ -76,7 +75,7 @@ EOT
|
|||||||
silence do
|
silence do
|
||||||
JSON.const_set :SAFE_STATE_PROTOTYPE, const
|
JSON.const_set :SAFE_STATE_PROTOTYPE, const
|
||||||
end
|
end
|
||||||
end if JSON.const_defined?("Ext")
|
end if JSON.const_defined?("Ext") && RUBY_ENGINE != 'jruby'
|
||||||
|
|
||||||
def test_generate
|
def test_generate
|
||||||
json = generate(@hash)
|
json = generate(@hash)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user