0

Using Rails 3, SimpleCov (0.9.2) gives me code coverage for all of my tests but fails to give me a report on what my automated Watir-Rails (1.2.1) browser calls in an ActionDispatch::IntegrationTest. Code that is called normally (ie not through Watir) shows up on the coverage fine. I've tried to configure my files like one would with the Selenium webdriver since I've heard that Watir is built on top of that, but that isn't doing the trick. Is there some extra setup I have to do in order to make it all work together?

andmcadams
  • 43
  • 5
  • maybe this coveralls example can help you https://coveralls.zendesk.com/hc/en-us/articles/201769485-Ruby-Rails – Dave McNulla Jun 24 '16 at 18:38
  • Can I use coveralls locally? I'm testing this project with everything on my own machine, so being able to test locally is preferred. – andmcadams Jun 28 '16 at 14:55
  • Coveralls uses simplecov. Rails had to be handled in a special way. – Dave McNulla Jun 28 '16 at 14:57
  • Whenever I run my tests using `rake test:integration` after following the Coveralls link, I get `[Coveralls] Outside the CI environment, not sending data.`. Is the test output printed to a file somewhere? Or is there an issue? – andmcadams Jun 28 '16 at 15:50
  • There should be a coverage/index.html file created. Open that in your browser. – Dave McNulla Jun 28 '16 at 18:36
  • Ah okay so it is the same file as SimpleCov has been outputting to. Coveralls doesn't seem to have changed the line covered count to reflect code covered by the Watir powered browser at all though. – andmcadams Jun 28 '16 at 18:49

0 Answers0