summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-12-12 09:03:33 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2015-12-12 09:03:33 +0000
commit3aeef6bcf0a43a86a621da73c90ce3c8c4e646e6 (patch)
treed4eaced8817dc5f8d0e92724cff900844baf740e
parent8e5595b5eea96f9077525530750e2f5f47766dec (diff)
test_thread.rb: stay alive
* test/ruby/test_thread.rb (test_thread_name): the target thread needs to stay alive till the end of this test, so that inspected result would not change. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53055 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--test/ruby/test_thread.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/ruby/test_thread.rb b/test/ruby/test_thread.rb
index 516014a..e0c61c6 100644
--- a/test/ruby/test_thread.rb
+++ b/test/ruby/test_thread.rb
@@ -1050,7 +1050,7 @@ q.pop
end
def test_thread_name
- t = Thread.start {}
+ t = Thread.start {sleep}
assert_nil t.name
s = t.inspect
t.name = 'foo'