Starting up with this:
it "doit avoir le bon titre" do
get 'home'
response.should have_selector("title", :content => "Simple App du Tutoriel Ruby on Rails | Accueil")
end
I ended up with that because I'm not on the same version of rspec or rails than the tutorial I'm following:
it "doit avoir le bon titre" do
get 'home'
expect(response).to have_selector("title", :text => "Simple App du Tutoriel Ruby on Rails | Accueil")
end
And now it's telling me this
Failure/Error: expect(response).to have_selector("title", :text => "Simple App du Tutoriel Ruby on Rails | Accueil")
expected to find css "title" with text "Simple App du Tutoriel Ruby on Rails | Accueil" but there were no matches
Why is it talking about CSS when all I want to do is validate the title? Am I doing it right considering I wanna do what the first sample of code is doing?
Obviously not because I have an error but what am I doing wrong?
Thanks.