-1

I'm running test towards browserstack with karma (karma-browserstack-launcher, browserify + reactify), using jasmine as test suite with my reactjs code, and I'm getting inconsistent behaviour.

If I run karma start karma.conf from my laptop (using Chrome 39 on windows 8.1), every test runs fine, but if I the command is run on travis-ci (via npm test), I get several exceptions, from missing objects to Error: Invariant Violation: findComponentRoot-errors from react. (The stacktrace from this error gives me no good lead on where to fix this)

I'm getting basically the same results if I use Firefox 35 on MAX OS X 10.10 and Firefox 35 on Windows 8.1, except from the Error: Invariant Violation: findComponentRoot-error from react.

If I run the tests with Firefox 35 on Windows 8.1 locally, the whole test blow up with the error ReferenceError: require is not defined from all the test-files.

What could be wrong here? Is there any reported inconsistency like this?

I'm not even sure where to report this error, since there's several players on the field (karma, browserstack, travis, jasmine, react).

phun-ky
  • 220
  • 2
  • 12
  • When using the JSX compiler I've noticed problems with null references not yet instantiated, when I run outside of the JSX compiler they seem to go away. – Chris Hawkes May 06 '15 at 19:12

1 Answers1

1

Turns out this was a blunder from my side. I forgot that when Travis CI initialize the job, it always installs the latest npm modules. I reinstalled the npm modules locally and got the same behaviour on both ends. Hope this will help someone else with the same issue :)

phun-ky
  • 220
  • 2
  • 12