Created
January 30, 2018 04:35
-
-
Save krainboltgreene/9874292893bca412a0895ac8bc9b107e to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
RSpec.describe "Some HTTP Request" do | |
before do | |
get "http://example.com" | |
end | |
it "is successful" do | |
expect(response).to have_http_status(:ok) | |
end | |
it "increments the visitor counter" do | |
expect { get "http://example.com" }.to change(Vistor, :count).from(0).to(1) | |
end | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
RSpec.describe "Some HTTP Request" do | |
it "is successful" do | |
get "http://example.com" | |
expect(response).to have_http_status(:ok) | |
end | |
it "increments the visitor counter" do | |
expect { get "http://example.com" }.to change(Vistor, :count).from(0).to(1) | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment