Questions tagged [cypress]
Cypress an all-in-one web testing framework and assertion library developed in JavaScript, complete with automatic waits, request mocking, and request stubbing.
cypress
9,937
questions
0
votes
0
answers
15
views
Running into issues when using BrowserStack with BDD Cypress
I have configured my Cypress tests with BDD, which works fine on my local or remote machine, but when tried to integrate them with BrowserStack its running into issues and the problem seems to be,
...
0
votes
1
answer
16
views
Scrolling in the table component with Cypress
I'm working on automating some testing with Cypress inside of SAP Hybris. Basically, I'm at the part where a list of promotions is given in the form of a table. The task that Cypress has to manage is ...
0
votes
1
answer
19
views
Configuration composent testing Cypress with StencilJS? [closed]
how to configure component testing with Cypress in a project using the StencilJS framework?
Cypress : v13
I was inspired by the configuration examples with the React and Angular framework, but ...
-1
votes
1
answer
41
views
no data in NYC .nyc_output/out.json = Angular18 + Cypress + Code Coverage
Minimum Reproducible Repo =
https://github.com/david-kirkland/ng18-code-coverage
I have started from scratch several times and cannot seem to get e2e test coverage using Angular 18, cypress, @cypress/...
0
votes
0
answers
17
views
How to import storybook stories into cypress for component test with angular
I am trying to use storybook with cypress on an angular app for component testing .My need is to create stories for angular components and use them in cypress .In React we can use ComposeStories ...
1
vote
3
answers
38
views
Cypress - Matching a query with a wildcard or regex
Consider the below code to intercept an API call. It checks if query parameter cliendId = 36. I want to make this code only consider the query param clientId and NOT its value of 36. So, I tried to ...
1
vote
1
answer
33
views
Handling unavailable price element with another element
So, I've made this web scraping script for Cypress. It goes to a shop website and scrapes the listed products (product titles and prices). Namely, in the case of certain products, there is no price ...
-1
votes
1
answer
24
views
Should I Run a Development Server or a Production Server for Cypress E2E Tests in CI? [closed]
I am currently running E2E tests for my React application using Cypress in a CI environment. Before executing the Cypress tests, I need to start the React server. I am undecided whether to run the ...
0
votes
0
answers
27
views
Problem accessing web elements using Cypress [closed]
I use Cypress and typescript. I ran into a problem.
The page has a form with a button and input fields.
Expected result: When you click the button, the input fields become available for editing.
...
0
votes
0
answers
19
views
There is a way of playing AVI video file via Cypress? [closed]
There is a way of playing AVI video file via Cypress?
I have a test that play video in a specific time, then it's export the played time to AVI file.
I need to open the AVI and play it via Cypress. It ...
0
votes
2
answers
64
views
Can I expect "time now" with leniency by a few minutes? [closed]
I'm using the dayjs function and wanted to try and add some leniency to the "time now" so that my test doesn't fail if it takes longer than a minute to run/load.
Currently I have the below ;
...
0
votes
0
answers
21
views
Configuration of gitlab.yml for smoke and full tests using the pipeline schedules
I would like to set up tests that will fire on the gitlab pipline. I would like to split the tests in cypress so that smoke fires once a day and all tests once a week. I have configured pipeline ...
1
vote
1
answer
41
views
How to run both storybook and cypress in headless mode
I am trying to use storybook and cypress for component testing with Angular framework .I am able to run test cases when storybook server and cypress are running separately but finding difficult to run ...
0
votes
1
answer
24
views
Return when cy.wrap failed [closed]
I have sometimes problems, that the line cy.wrap... break, when the IDTest element load to long.
I am looking for a way, that this line jump back with an return to the function when this line failed.
...
0
votes
0
answers
19
views
Cypress Your test are loading after submit [closed]
Are there any bugs in Cypress that prevent this from happening? I created a function for the signup flow, and after submission, Cypress reloads the test.
cy.get('[data-cy="button-submit-signup&...
-1
votes
1
answer
37
views
When using nextjs with cypress to render coverage I keep getting error on declaring the global namespace
See example repo:
https://github.com/inspiraller/nextjs-with-cypress-coverage
tsconfig.json
{
"compilerOptions": {
"baseUrl": ".",
"lib": ["dom&...
0
votes
0
answers
18
views
Cypress skips the first letter when typing [closed]
I'm building a table in react and I'm testing it with cypress.
I have a component that turns into an input when focused and pressed. For an unknown reason Cypress is not typing this first letter. Here ...
0
votes
0
answers
28
views
Getting 404 in Cypress test [closed]
I'm getting started with Cypress but I got stuck at the "hello world" of it ! I'm trying to open a page, first it worked like a charm, then all of a sudden the webstie started giving 404 ...
0
votes
0
answers
22
views
Assigning input value to variable in Cypress [duplicate]
For a Cypress e2e test I need to read out the value of an input field into a variable, but I haven't found a proper way to do this. First, I tried this:
cy.get('[data-cy=password-input]')
.invoke('...
-1
votes
0
answers
39
views
Running Cypress tests as a Gradle task yields non-ASCII characters
This topic has been discussed at length. I've read several posts on Github and SO, however I am unable to find a reliable solution. My question is specific to the Windows 11 environment, Java 17 and ...
0
votes
0
answers
13
views
common method for Click using Cypress [closed]
i have declared elements in page Object class as below
` elements = {
imageButtonRole: () => cy.get('li[title="Change Role"]', { timeout: tout }).children('img'),
}`
now i ...
2
votes
2
answers
73
views
Using alias from before() in a it() test
In this example on the website, they say there is a simple way to use data you create in before() or beforeEach() in a testcase it(). But when I tried it it said my this.variable was undefined. After ...
0
votes
1
answer
41
views
cypress-cucumber-preprocessor dry option not working
How to use dry run option in cypress-cucumber-preprocessor package, so that I can get respective step definition for feature files. I have gone through the following link and used the command
npx ...
0
votes
0
answers
15
views
How use each in cypress when element is detached from DOM after action [duplicate]
I have this cypress code and it works. I need to iterate through all the links on the page. After clicking on each link, a breadcrumb tab opens. After closing the tab, the page with the links returns.
...
0
votes
0
answers
15
views
My Cypress tests are throwing CORS issues only when MS Clarity is enabled through our A/B Testing Tool
The Problem
When MS Clarity is enabled through our A/B Testing Tool, my CI/CD pipeline is throwing issues. Cypress says that an uncaught error was thrown from a cross-origin script. On production, ...
-3
votes
1
answer
50
views
Read value of key from one json file to another json file [closed]
I am doing Cypress automation with JavaScript. In this, I want to read value of one JSON file to another JSON file. And based on that want to retrieve other values.
Below is my credentials.json file:
{...
4
votes
1
answer
69
views
Cypress Component Testing in Angular Shadow Dom Components
I am trying to run Cypress component testing on a library of Angular components. Currently, all of my components have shadowDom turned on. Which seems to be causing me a problem when running multiple ...
0
votes
2
answers
42
views
cypress - how to continue running loop after assertion error
I have test that opens every item on the list. Then it validates if there are no empty ('--') fields. I want to log in console that there were empty fields and go to another item and run the loop till ...
-1
votes
0
answers
36
views
Cypress : Argument of type '(this: Context, query: any) => Bluebird<unknown>' is not assignable to parameter of type 'CommandFn [closed]
I am writing custom command in commands.ts file using Cypress and get the following error:
Argument of type '(this: Context, query: any) => Bluebird' is not assignable to parameter of type '...
0
votes
0
answers
44
views
cypress-firebase emulator default credentials error
i'm using React and Firebase to build an web app and i would like to use Cypress to do some end to end testing. I am new to Cypress. I'm trying to setup Cypress-Firebase NPM package but i'm getting ...