[rspec-users] rspec-rails img src and timestamps

amkirwan amkirwan at gmail.com
Thu Jun 4 21:54:55 EDT 2009


I found the answer to my own question. Just needed to use image_path
("logo.jpg"). Incase anyone else has this is I hope this helps.

response.should have_selector("#logo", :src => image_path("logo.jpg"))

On Jun 4, 9:19 pm, amkirwan <amkir... at gmail.com> wrote:
> when I run the following matcher bellow it fails because rails adds
> the timestamp after the file name. I've looked around but have not
> found anyone else having this problem. I am new to rails and rspec so
> maybe I am completely missing something obvious.
>
>  response.should have_selector("#logo", :src => "/images/logo.jpg")
> _______________________________________________
> rspec-users mailing list
> rspec-us... at rubyforge.orghttp://rubyforge.org/mailman/listinfo/rspec-users


More information about the rspec-users mailing list