Questions tagged [angular-e2e]

This tag should be used when asking questions about angular end to end testing, in combination for example with protractor which is the official angular framework for writing end to end tests. this will help to categorize these questions and get the right solutions for them.

153 questions
18
votes
5 answers

session not created: Chrome version must be between 71 and 75 - while running angular e2e in Concourse

While executing e2e test in concourse, I'm getting the below error, where it looks like the chromedriver is not getting updated. While similar problems were discussing about chrome version falling behind, in my case, the chrome stable version is…
Prasanth Mohan
  • 235
  • 1
  • 2
  • 9
17
votes
3 answers

Protractor - invalid SSL certificate

We have an application and testing this locally shows an invalid SSL certificate warning. Normally I would just add an exception and get on with it. However is there anyway for protractor to ignore this? I've seen some capabilities in selenium…
Joseph
  • 337
  • 1
  • 3
  • 16
10
votes
3 answers

Angular migration (from 4 to 6) e2e --proxy-config not working

I've been currently migrating my app from 4 to 6 and I can not executing my proxy script for my e2e tests. The script listing looks as follows: "scripts": { "ng": "ng", "start": "ng serve", "start:tst1": "ng serve --proxy-config…
MarcoLe
  • 1,639
  • 3
  • 22
  • 59
9
votes
0 answers

Why is data-* attributes preferred for element selection over a plain ID attribute?

Cypress and many other posts around testing web applications suggest relying on a data attribute like data-cy or data-test-id for locating elements rather than relying on the id attribute. My understanding is that for two reasons: The modern way of…
9
votes
3 answers

Run angular end-to-end tests in watch mode

Currently, I run ng e2e every time I make a change in my spec files and every time this command rebuilds the entire project ! is there a way to run the tests without rebuilding the entire project, just like ng test does it.
Rachid Oussanaa
  • 10,348
  • 14
  • 54
  • 83
8
votes
5 answers

Protractor can't detect Angular 5 on deployed application

I am trying to create a repository with E2E tests for my web application using Protractor and Cucumber. I have started with this repository: https://github.com/spektrakel-blog/angular-protractor-cucumber When I am forcing Protractor to treat the…
mc.suchecki
  • 1,767
  • 3
  • 22
  • 43
6
votes
1 answer

Failed: script timeout: result was not received in 11 seconds From: Task: Protractor.waitForAngular() - Locator: By(css selector, #my-btn)

I'm trying to write some e2e test for my Angular application using Protractor. I have a simple html button having id=my-btn which I want to click, using: $('#my-btn').click(); Unfortunately I'm getting the following errors: Failed: script timeout:…
Francesco Borzi
  • 37,945
  • 31
  • 126
  • 195
5
votes
0 answers

Running 'ng e2e' doesn't output anything to the console

When I run ng e2e in my angular 7 project root, it doesn't start the dev server and just quits after about 9-10 seconds. I've tried to create a new project and compare the package.json and angular.json. All the angular dependencies are the same…
dan070
  • 239
  • 4
  • 12
5
votes
1 answer

Test an element is in viewport with protractor

I want to test if my app scrolled to a specific post inside a thread page. Initially I thought isDisplayed might help, and coded something like: element(by.id(postId)).isDisplayed().then((isDisplayed) => { …
Robert T.
  • 1,102
  • 1
  • 8
  • 17
5
votes
3 answers

Angular 2 e2e using protractor: by.model not working

While writing test cases using protractor.js for Angular 2 application , if I want to get element(by.model("xyz.test")) its always giving failure saying angular is not defined. Any idea how to fix this issue?
4
votes
0 answers

E2E Testing using cypress - Azure AD Single Sign On

I have been trying to achieve end to end testing using cypress in my angular project and is stuck with a single sign-on issue. Please help me with possible approaches. Briefing: My Angular application uses Azure AD Microsoft login to authenticate…
Ash
  • 51
  • 6
4
votes
2 answers

Error code: 135 ,How to fix error: Could not find update-config.json. Run ‘webdriver-manager update’ to download binaries

[17:05:22] I/launcher – Running 1 instances of WebDriver [17:05:22] I/direct – Using ChromeDriver directly… [17:05:22] E/direct – Error code: 135 [17:05:22] E/direct – Error message: Could not find update-config.json. Run ‘webdriver-manager…
Sobhana
  • 145
  • 1
  • 6
4
votes
3 answers

How to disable or bypass MSAL authentication when running Angular e2e tests?

I want to set up some end to end tests for my Angular application, which requires the use of the MSAL library to authenticate with some downstream services. When I try to run my e2e tests locally, the MSAL library is forcing me to authenticate with…
Alan Bentley
  • 81
  • 1
  • 6
4
votes
1 answer

Why does nrwl nx create a separate e2e project for each app?

When creating a new nx workspace (i.e. with create-nx-workspace) and then generating an app (with ng g app) it creates an app folder inside the apps folder (so far so good) and also another app-e2e folder, also inside the apps folder. In my mind it…
4
votes
2 answers

E2E Angular 6 websocket mocking

We've recently started using Cypress for our E2E tests with our Angular 6 UI. It's proving to be great and, in our opinion, much better to use than Protractor. Our plan is to mock all interactions with the server. This has been easy for all…
eebsie
  • 279
  • 3
  • 16
1
2 3
10 11