diff options
author | eregon <eregon@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2018-04-25 08:11:01 +0000 |
---|---|---|
committer | eregon <eregon@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2018-04-25 08:11:01 +0000 |
commit | 66058dd546df0b7ae14bc146ea2c5e7710ef385c (patch) | |
tree | e5b6bb40aecd0c3a071c23d746a875a28a91df8c /spec/ruby/core/thread/raise_spec.rb | |
parent | 067066fc9b2c3edf114974082a2172ca8527a4bf (diff) | |
download | ruby-66058dd546df0b7ae14bc146ea2c5e7710ef385c.tar.gz |
Use Thread.pass in loop{} to check interrupts more often
* The spec now runs in ~5ms vs ~100ms before.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63256 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'spec/ruby/core/thread/raise_spec.rb')
-rw-r--r-- | spec/ruby/core/thread/raise_spec.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/spec/ruby/core/thread/raise_spec.rb b/spec/ruby/core/thread/raise_spec.rb index f5dd18b7e5..20c8b149b8 100644 --- a/spec/ruby/core/thread/raise_spec.rb +++ b/spec/ruby/core/thread/raise_spec.rb @@ -151,7 +151,7 @@ describe "Thread#raise on a running thread" do 1/0 rescue ZeroDivisionError raised = true - loop { } + loop { Thread.pass } end end begin |