Skip to content
This repository has been archived by the owner on Dec 1, 2021. It is now read-only.

Commit

Permalink
roll back the answers I accidently merged
Browse files Browse the repository at this point in the history
  • Loading branch information
reneedv committed Jan 14, 2014
1 parent dc0dd34 commit f111e4d
Showing 1 changed file with 20 additions and 20 deletions.
40 changes: 20 additions & 20 deletions week1/exercises/rspec_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

describe "The Rspec ruby gem" do

context "Domain Specific Language" do
context "Domain Specific Language" do

it "creates examples with the #it keyword" do

Expand Down Expand Up @@ -43,7 +43,7 @@

# When this example fails,
# it will show "expected" as 2, and "actual" as 1
1.should_not eq 2
1.should eq 2

end

Expand All @@ -53,7 +53,7 @@

# The following expression is false.
# However, this example PASSES because no expectation was created.
true.should_not eq false
true == false

# The following line of code is correct, and would cause the example to fail:
# true.should == false
Expand All @@ -63,34 +63,34 @@
end

it "should count the characters in my name" do
"Renée".should have(5).characters
"Renée".should have(5).characters
end

it "should check how to spell my name" do
"Renée".should include("ée")
"Renée".should include("ée")
end

end

context "Examples for in-class test exploration" do
it "should know order of operations" do
# Fix the Failing Test
# Order of Operations is Please Excuse My Dear Aunt Sally:
# Parentheses, Exponents, Multiplication, Division, Addition, Subtraction
(1+2-5*6/2).should eq -12
end
it "should count the characters in your name" do
"doga".should_not eq "tuncay"
it "should know order of operations" do
# Fix the Failing Test
# Order of Operations is Please Excuse My Dear Aunt Sally:
# Parentheses, Exponents, Multiplication, Division, Addition, Subtraction
((((1+2)-5)*6)/2).should eq -6
end
it "should count the characters in your name" do
"Tom".should have(3).characters
end

it "should check basic math" do
(40+2).should eq 42
end

it "should check basic math" do
1.should_not eq "tuncay"


it "should check basic spelling" do
(2*2).should_not 3
it "should check basic spelling" do
"Field".should include('ie')
end

end

end

0 comments on commit f111e4d

Please sign in to comment.