Why Capypara + Rspect tests still pass even though I delete application.js file?
Asked Answered
S

1

6

I have rails app and have some ajax call in application.js file. O have rspec, capybara, webkit, factorygirl and databasecleaner for testing. I wrote feature tests which all pass. Then accidentally delete application.js file and run the tests, they still pass. Please help me to find out why. Thanks so much.

PS: if you downvote my question, please at least tell me why. I have been searching for answers but couldn't find one.

Smearcase answered 4/11, 2016 at 7:36 Comment(2)
have you tried with rake assets:clean , rake assets:clobber and rake assets:precompile ?Detestable
@fabersky rake assets:clobber worked, those cached file in public folder was the reason. Thanks so much man!Smearcase
D
9

Try with

rake assets:clobber

This will remove compiled assets and clean them.

Detestable answered 5/11, 2016 at 18:54 Comment(1)
thanks! in my case was driving nuts because my feature tests were calling to a deleted methodSlogan

© 2022 - 2024 — McMap. All rights reserved.