Hi,
I'm currently trying to add code coverage into an angular application. Followed all the instructions and all seems to work fine if I explicitly open cypress using this script in package.json "cypress:open": "cypress open --config-file cypress-config/cypress.local.json". Report gets generated and all is fine.
As it's stated in the documentation this example removes protractor and adds cypress instead. This means that I should successfully use the ng e2e command to run the tests.
My issue is that I'm using a different configuration file for cypress, not the default one cypress.json that sits in the root of the project and because of that when trying to run ng e2e this doesn't load the correct configurations. Also when using ng e2e it doesn't load the custom commands that I defined in cypress.
Any idea how to fix these two issues:
get ng e2e to load the correct cypress configuration file
Hi, I'm currently trying to add code coverage into an angular application. Followed all the instructions and all seems to work fine if I explicitly open cypress using this script in package.json
"cypress:open": "cypress open --config-file cypress-config/cypress.local.json"
. Report gets generated and all is fine.As it's stated in the documentation this example removes protractor and adds cypress instead. This means that I should successfully use the
ng e2e
command to run the tests. My issue is that I'm using a different configuration file for cypress, not the default onecypress.json
that sits in the root of the project and because of that when trying to runng e2e
this doesn't load the correct configurations. Also when usingng e2e
it doesn't load the custom commands that I defined in cypress.Any idea how to fix these two issues:
ng e2e
to load the correct cypress configuration file