TypeError: 'null' is not an object (evaluating 'currentSpec.expect')
danielbsig opened this issue · comments
The following error occurs occasionally (not always) when we run our tests using gulp-karma. However, if the tests are executed using karma alone, this does not occur.
Seems to be a problem on Windows only.
Any ideas what might be the problem?
currentSpec.expect
is part of of Jasmine, so this could be a problem with your Karma plugin configuration or Jasmine itself... It is odd that the behavior is only observed when running with gulp-karma
, but I can't think of a reason why that could ever happen due to what gulp-karma
does.
it might have something to do with the gulp.src we're passing. Is it possible to use the file array defined in karma.conf.js?
The plugin is in flux right now and will definitely not be using gulp.src()
to specify files in the future. See karma-runner/karma#1037, where @pkozlowski-opensource and I discuss that this plugin really shouldn't exist, we just need a few features in Karma to make it usable directly from gulp.
The problem is probably in some other component (karma-jasmine or jasmine itself), so I will close this issue.