spec/unit/comments_spec.rb in activeadmin-1.0.0.pre2 vs spec/unit/comments_spec.rb in activeadmin-1.0.0.pre3
- old
+ new
@@ -157,32 +157,32 @@
describe "#comments?" do
it "should have comments when the namespace allows comments" do
ns = ActiveAdmin::Namespace.new(application, :admin)
ns.comments = true
- expect(ns.comments?).to be_truthy
+ expect(ns.comments?).to eq true
end
it "should not have comments when the namespace does not allow comments" do
ns = ActiveAdmin::Namespace.new(application, :admin)
ns.comments = false
- expect(ns.comments?).to be_falsey
+ expect(ns.comments?).to eq false
end
end
end
describe ActiveAdmin::Comments::ResourceHelper do
it "should add an attr_accessor :comments to ActiveAdmin::Resource" do
ns = ActiveAdmin::Namespace.new(application, :admin)
resource = ActiveAdmin::Resource.new(ns, Post)
- expect(resource.comments).to be_nil
+ expect(resource.comments).to eq nil
resource.comments = true
- expect(resource.comments).to be_truthy
+ expect(resource.comments).to eq true
end
it "should disable comments if set to false" do
ns = ActiveAdmin::Namespace.new(application, :admin)
resource = ActiveAdmin::Resource.new(ns, Post)
resource.comments = false
- expect(resource.comments?).to be_falsey
+ expect(resource.comments?).to eq false
end
end
end