Skip to content

Commit 438fdf8

Browse files
Eliminate use of be_true/be_false
1 parent 74a280a commit 438fdf8

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

spec/commentable_spec.rb

+5-5
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
describe "A class that is commentable" do
44
it "can have many root comments" do
5-
Commentable.new.comment_threads.respond_to?(:each).should be_true
5+
Commentable.new.comment_threads.respond_to?(:each).should eq(true)
66
end
77

88
describe "when is destroyed" do
@@ -65,12 +65,12 @@
6565
end
6666

6767
it "should return comments by the passed user" do
68-
@comments.all? { |c| c.user == @user }.should be_true
68+
@comments.all? { |c| c.user == @user }.should eq(true)
6969
end
7070

7171

7272
it "should not return comments by other users" do
73-
@comments.any? { |c| c.user != @user }.should be_false
73+
@comments.any? { |c| c.user != @user }.should eq(false)
7474
end
7575
end
7676
end
@@ -89,12 +89,12 @@
8989
end
9090

9191
it "should return its own comments, ordered with the newest first" do
92-
@comments.all? { |c| c.commentable_type == @commentable.class.to_s and c.commentable_id == @commentable.id }.should be_true
92+
@comments.all? { |c| c.commentable_type == @commentable.class.to_s and c.commentable_id == @commentable.id }.should eq(true)
9393
@comments.each_cons(2) { |c, c2| c.created_at.should > c2.created_at }
9494
end
9595

9696
it "should not include comments for other commentables" do
97-
@comments.any? { |c| c.commentable_type != @commentable.class.to_s or c.commentable_id != @commentable.id }.should be_false
97+
@comments.any? { |c| c.commentable_type != @commentable.class.to_s or c.commentable_id != @commentable.id }.should eq(false)
9898
end
9999
end
100100
end

0 commit comments

Comments
 (0)