grunt-protractor-coverage
grunt-protractor-coverage copied to clipboard
makeReport throws Cannot read property 'text' of undefined error
makeReport task throws error as below,
[4mRunning "makeReport" task[24m [31mFatal error: Cannot read property 'text' of undefined[39m
I'm able to see the lcov files with index.html (reports/lcov-report/index.html) with coverage data at the high level, but link to individual file level details are broken. Looking around I couldn't get much details about this error, so want to know if its an issue with the grunt-protractor-coverage or configuration in my project.
Hi chinnipayrange, Were you able to debug this issue? Am facing the same issue. Please let me know if you have any fix for this.
Thanks!
Nope I couldn't debug the issue as my priorities changed. Since I'm able to get the coverage reports, for now I'm living with it.
I am also facing same issue. Please post solution if you find one
Solved this issue by placing back original non-instrumented *.js files in folders. I was placing instrumented code to replace original files as can't get connect task to work.
Confirmed. This issue is solved by coping back non-instrumented files over your instrumented files before running the makeReport task. Executing the makeReport task on instrumented files corrupts the HTML report. You cannot drill down from lcov-report/index.html to your source code report files.
From my Gruntfile: grunt.registerTask('coverage', ['jshint', 'clean:coverage', 'copy', 'instrument', 'forever:test:restart', 'protractor_coverage', 'copy', 'makeReport']);
The 'copy' task grabs non-instrumented files from my build output.
please close this PR.