167 questions
0
votes
0
answers
933
views
How to automatically add data-testid to all UI elements of an angular application
I am working on a angular project having thousands of html files. Now we are trying to implement UI test automation using cypress. However, we are facing some difficulties in uniquely identify UI ...
0
votes
2
answers
189
views
Is there an equivalent to an 'containsExact' function in Cypress?
I have a Cypress E2E test suite in which I want to search for row in a table by the text displayed in the table cells.
I've had some success with the following:
cy.get('.p-datatable-tbody').should('be....
1
vote
1
answer
823
views
How to configure Cypress component testing when Cypress is installed outside the Frontend project
I have a Front-end App for that I am using cypress e2e testing.
The structure of this is : a folder with the (Angular) FE app; and outside this, another folder with the cypress installation. In my env ...
0
votes
2
answers
7k
views
Playwright. How to skip all tests in a group if selector not found?
I am developing E2E tests with Playwright for angular app. I have to ensure that needed conditional selector exists in order to proceed, otherwise skip further tests.
In other words I need to skip all ...
0
votes
1
answer
254
views
Testcafe run failed (Angular 14.2.1)
I'm trying to run e2e testcases with testcafe in Angular 14.2.1.
For the setup I have used the mentioned documentation from the testcafe page:
https://medium.com/test-automation-pro/testcafe-tests-in-...
0
votes
1
answer
629
views
How can I click on first button with data-cy equal to other buttons?
I'm new to test e2e and I'm trying to click on a specific button, I gave it a data-cy that automatically is been attributed to other buttons created dynamically.
How can I click on first button? The ...
2
votes
1
answer
2k
views
Cypress 10: Custom command is not a function
I have this error, cy. is not a function:
But I already updated the e2e.ts with this:
import './commands';
Here is my commands.ts:
declare namespace Cypress {
interface Chainable<Subject = ...
4
votes
1
answer
5k
views
Cypress net::ERR_EMPTY_RESPONSE on real server calls
I'm trying to test my fullstack angular-nestjs-application with cypress e2e tests.
Server calls from within angular to not reach my backend running on localhost:443 (I tested it with 0.0.0.0, 127.0.0....
0
votes
0
answers
17
views
angular e2e tests - json object forEach method used in data driven tests throw "not a function error" [duplicate]
Have a data.json file and trying to use json data in e2e tests as given in below example.
https://www.c-sharpcorner.com/article/data-driven-testing-in-protractor/
The example works fine with github ...
4
votes
0
answers
3k
views
How to fix zone-testing.js is needed for the fakeAsync() test helper but could not be found
I'm having this error when trying to run e2e tests with protractor in my angular 12 application,
- Failed: zone-testing.js is needed for the fakeAsync() test helper but could not be found.
...
3
votes
1
answer
2k
views
Cypress XHR requests get aborted when running headless, in cypress based image container
Cypress XHR requests get aborted when running headless, in a cypress-based image container.
Browser: Electron
describe('Test Sign-In and search', () => {
before(() => {
cy....
3
votes
1
answer
4k
views
Angular 13.x - How to fix import * as i0 from '@angular/core' issue?
I did upgrade my app from Angular 12.x to version 13.x
Build and Serve etc. work fine. But when I try to execute e2e-test I face following error:
E/launcher - Error: /Users/userName/PROJECT_NAME/...
0
votes
1
answer
384
views
Cypress, get the numeric value of an attribute
To avoid going crazy again, is it possible to get the value of the htmlTemplateof this element?
<rect x="303" y="28" height="53" width="10" htmlTemplate=&...
-2
votes
1
answer
1k
views
How to read environment files from e2e tests?
Here's the structure of my Angular application:
MyApplication
apps
- app1
- src
- app
- assets
- environments //*****USE THIS FILES ****
...
0
votes
1
answer
780
views
Angular E2E acces environment variables
So I'm using NX with Angular and I have multiple apps with two possible authentification methods. Therefore I need to have a E2E test, that tests both authentification methods, because they differ in ...