Skip to content
Advertisement

Tag: cypress

Cypress is not running in ci SyntaxError: Unexpected token ‘export’ with cypress-io/github-action@v2 typescript

I have the following plugin file for cypress: frontend/cypress/plugins/index.ts: When I run it on my machine it’s working but when I use cypress-io/github-action@v2 in my github actions I get the following error: This is my .github/workflows/cypress-tests.yml: My frontend/cypress.json config file is empty. This is my frontend/cypress/tsconfig.json in the cypress folder: This frontend/cypress/plugins/tsconfig.jsonis inside the Plugins folder: I have copied this

Time comparison in Cypress

Issue occurs when I need to check for example that 11AM was 2hours before 1PM as my code takes difference as 10.(11 vs 1) as we have 12 hour time. Answer I notice you have the dayjs library. To handle parsing strings with various, add the customParseFormat plugin. Your dateString is passed into dayjs(dateString, format) as 1st parameter and format

Verify the checkbox is checked in Cypress

I want to verify the checkbox is checked. This is the HTML for the checkbox the js for it: Then on step definition: strangely Cypress shows that the expected value was true but the value was true Answer You have to change true to ‘true’. The true is a string.

How to retrieve Token for API calls in cypress

Due to a lack of knowledge in JS, I do face with below problem. I do automation testing with cypress and for external API endpoints, I need to use Dynamic Token that expires every 3600 secs. I did some short research and find out that, for reaching to JWT Token I will need 1st SSO login (that my app has).

Advertisement