/
Javascript - I see no coverage in Front End Tests
Javascript - I see no coverage in Front End Tests
Problem
I have instrumented my code and used it however I see no coverage reported for my files.
Solutions
Disable caching in your Browser
In Chrome, open the Developer mode (F12), and check the 'Disable cache option under the Network tab.
Validate the Instrumentation and build number in the JS source from the Browser
In your Browser, open the source code of your JS page: is there the Sealights' instrumentation code and the right build number?
Validate the application is using instrumented source and not compressed files from the Build stage
Check JS is not compressed at the Application Server and therefore confirm the instrumented files are the one used
Validate the application is using the static instrumented files and not files in memory
Check your configuration is not using a In-Memory server (e.g. Webpack's server) and serves to your browser client the static files instrumented
You can try a simple http server like httpster for a quick validation via a command similar to
httpster -p 8080 -d /home/somedir/public_html
, multiple selections available,
Related content
Running tests using Jest framework
Running tests using Jest framework
More like this
Unit Tests - SeaLights Node.js Agent
Unit Tests - SeaLights Node.js Agent
More like this
Coverage - SOME methods are not showing as covered in SeaLights
Coverage - SOME methods are not showing as covered in SeaLights
More like this
Running Tests using Karma test framework
Running Tests using Karma test framework
More like this
Using Node.js Agents - Scanning a build
Using Node.js Agents - Scanning a build
More like this
SeaLights Node.js agent - Scanning and Instrumentation of a Front-End app
SeaLights Node.js agent - Scanning and Instrumentation of a Front-End app
More like this