mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* test/ruby/test_thread.rb (test_thread_join_in_trap):
Run the test in a different process. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@43540 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
3ce802b79c
commit
7835e321ea
2 changed files with 9 additions and 0 deletions
|
@ -1,3 +1,8 @@
|
||||||
|
Tue Nov 5 21:21:47 2013 Tanaka Akira <akr@fsij.org>
|
||||||
|
|
||||||
|
* test/ruby/test_thread.rb (test_thread_join_in_trap):
|
||||||
|
Run the test in a different process.
|
||||||
|
|
||||||
Tue Nov 5 20:14:32 2013 Masaya Tarui <tarui@ruby-lang.org>
|
Tue Nov 5 20:14:32 2013 Masaya Tarui <tarui@ruby-lang.org>
|
||||||
|
|
||||||
* gc.c (is_live_object): A hidden object may be a live object.
|
* gc.c (is_live_object): A hidden object may be a live object.
|
||||||
|
|
|
@ -725,6 +725,7 @@ _eom
|
||||||
end
|
end
|
||||||
|
|
||||||
def test_thread_join_in_trap
|
def test_thread_join_in_trap
|
||||||
|
assert_separately [], <<-'EOS'
|
||||||
assert_nothing_raised{
|
assert_nothing_raised{
|
||||||
t = Thread.new{ sleep 0.2; Process.kill(:INT, $$) }
|
t = Thread.new{ sleep 0.2; Process.kill(:INT, $$) }
|
||||||
|
|
||||||
|
@ -734,7 +735,9 @@ _eom
|
||||||
|
|
||||||
t.join
|
t.join
|
||||||
}
|
}
|
||||||
|
EOS
|
||||||
|
|
||||||
|
assert_separately [], <<-'EOS'
|
||||||
assert_equal(:normal_end,
|
assert_equal(:normal_end,
|
||||||
begin
|
begin
|
||||||
t = Thread.new{ sleep 0.2; Process.kill(:INT, $$); :normal_end }
|
t = Thread.new{ sleep 0.2; Process.kill(:INT, $$); :normal_end }
|
||||||
|
@ -745,6 +748,7 @@ _eom
|
||||||
t.value
|
t.value
|
||||||
end
|
end
|
||||||
)
|
)
|
||||||
|
EOS
|
||||||
end
|
end
|
||||||
|
|
||||||
def test_thread_join_current
|
def test_thread_join_current
|
||||||
|
|
Loading…
Reference in a new issue