Advertisement
saasbook

rspec_matcher.rb

Feb 13th, 2016
213
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Ruby 0.39 KB | None | 0 0
  1. require 'foo'
  2. describe Foo do
  3.   describe "a new foo" do
  4.     before :each do ; @foo = Foo.new ; end
  5.     it "is a pain in the butt" do
  6.       expect(@foo).to  be_a_pain_in_the_butt
  7.     end
  8.     it "is awesome" do
  9.       expect(@foo).to  be_awesome
  10.     end
  11.     it "is not nil" do
  12.       expect(@foo).to_not  be_nil
  13.     end
  14.     it "is not the empty string" do
  15.       expect(@foo).to_not eq ""
  16.     end
  17.   end
  18. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement