summaryrefslogtreecommitdiff
path: root/spec/ruby/core/mutex/try_lock_spec.rb
diff options
context:
space:
mode:
Diffstat (limited to 'spec/ruby/core/mutex/try_lock_spec.rb')
-rw-r--r--spec/ruby/core/mutex/try_lock_spec.rb10
1 files changed, 5 insertions, 5 deletions
diff --git a/spec/ruby/core/mutex/try_lock_spec.rb b/spec/ruby/core/mutex/try_lock_spec.rb
index 3e875ff9ec..1da0735d6a 100644
--- a/spec/ruby/core/mutex/try_lock_spec.rb
+++ b/spec/ruby/core/mutex/try_lock_spec.rb
@@ -1,16 +1,16 @@
-require File.expand_path('../../../spec_helper', __FILE__)
+require_relative '../../spec_helper'
describe "Mutex#try_lock" do
describe "when unlocked" do
it "returns true" do
m = Mutex.new
- m.try_lock.should be_true
+ m.try_lock.should == true
end
it "locks the mutex" do
m = Mutex.new
m.try_lock
- m.locked?.should be_true
+ m.locked?.should == true
end
end
@@ -18,7 +18,7 @@ describe "Mutex#try_lock" do
it "returns false" do
m = Mutex.new
m.lock
- m.try_lock.should be_false
+ m.try_lock.should == false
end
end
@@ -26,7 +26,7 @@ describe "Mutex#try_lock" do
it "returns false" do
m = Mutex.new
m.lock
- Thread.new { m.try_lock }.value.should be_false
+ Thread.new { m.try_lock }.value.should == false
end
end
end