Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # The crutial thing here is that the work inside "run" is only done once.
- # There should be no side-effects inside the examples
- Spec.describe "When making a request to '/login'" do
- describe "as an unauthenticated user" do
- run do
- @response = request("/login")
- end
- it "returns a 401 status" do
- @response.status.should == 401
- end
- it "contains the login form" do
- @response.body.should have_selector("/something/i/can/not/work/out")
- end
- end
- end
Add Comment
Please, Sign In to add comment