jeudi 25 mai 2017

How to test parsed page with rspec

I have news page which parsed from other site. I want to make a test to sure that base site has correct css/body elements (which was when i wrote parser). I read about webmock and vcr but still can't understand how to use it. I need something like this in test:

expect(**page**).to have_css(".news image")

I want to be sure that page is original page, from I want to parse. Is it possible to make this test?

Aucun commentaire:

Enregistrer un commentaire