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.

167 questions
0
votes
0 answers

"browser.findElements" works, but "element.all" doesn't

I am testing a form in Angular 9, and I want to check if any error messages are displayed using Protractor 5.4.3. Error messages are shown according to an *ngIf. Outside the test, the code works normally. If I do the search as the official…
0
votes
1 answer

Correct way to use async function inside a for-loop

Recently, I got some error when running the E2E tests and the only change I made is adding the checkColumns logic in the original test code as following: it('check search and sort', async () => { await checkLoadingAndResult(); await…
0
votes
1 answer

Tag filter system - Cucumber

I am working on a project where there may be several configurations (site for customer A , site for customer B,...). Each configuration has potentially different interactions (it is rare). So I wrote my code with scenarios for certain…
dadadaa
  • 55
  • 2
  • 9
0
votes
2 answers

Executing e2e test in angular based on configuration

I am working on a project on Angular7 where e2e tests are written using protractor. I have made a new feature in my project which I want to control via a functional switch. When switch is ON feature will be rendered to user and hidden when switch is…
AkashSharma
  • 107
  • 1
  • 2
  • 13
0
votes
1 answer

E2E Test application flow on multiple devices

Our applications flow start on desktop. At later phase there are some scenarios where the processes require an approval on a touch device. The user waits at a page on desktop. If the user opens the same page (same angular application) on a touch…
0
votes
3 answers

Angular Protractor - Verifying page redirect

I'm writing a few E2E tests in an Angular application. A problem I'm having is that whenever I redirect to a new route, I'd like to verify that the correct component is being displayed. For some reason this is always resulting a failure with the…
Daniel Grima
  • 2,765
  • 7
  • 34
  • 58
0
votes
1 answer

When using Angular CLI's "ng e2e", is it possible to have Protractor use Jasmine 3.5? OR fail fast with ng e2e

I'm wanting to use some of the features within Jasmine 3.5 like oneFailurePerSpec. If there's a way to do that with Jasmine 2.8, please point me there because it looks like Protractor 5.4.2 uses Jasmine 2.8. Right now, I'm using a custom reporter to…
0
votes
2 answers

When should element.all(locator).then(thenFunction) or element.all(locator) be used?

In protractor, what's the difference between (source): Example 1 const allOptions = element.all(by.options('fruit for fruit in fruits')); expect(await allOptions.count()).toEqual(4); and (source): Example 2 const arr = await…
Francesco
  • 405
  • 3
  • 15
0
votes
1 answer

element not attached to page document, async functions running simultaneously

I cannot solve the following problem, neither could I find any info regarding it, so it's time to post it here: I have the following piece of code const smdb = new SmdbPage; const edit = new SmdbEdit; describe('SMDB Edit:', () => { it('should…
Peter Toth
  • 678
  • 6
  • 23
0
votes
2 answers

Angular e2e test with Protractor: click intercepted by parent of element selected by id

Sometimes I get this error but not every time I run the test. What is causing this strange behavior? Failed: element click intercepted: Element
...
is not clickable at point (616, 104). Other element would receive the…
0
votes
0 answers

How set proxy auth in e2e?

I need help with auth in proxy with my e2e protractor. A part of my protractor.conf.js: capabilities: { 'browserName': 'chrome', proxy: { proxyType: 'manual', httpProxy: 'http://xxx.xxx.xxx.xxx:port', } }, That's work…
J. Doe
  • 447
  • 1
  • 4
  • 7
0
votes
1 answer

File upload with protractor is not working

I am trying to upload a file to web form on e2e test with protractor. The file is not uploaded and the input field stay empty. this is the code: it('should uploaded', ()=>{ const fileToUpload = '../src/files/somefile.csv'; …
Eliran
  • 157
  • 1
  • 13
0
votes
1 answer

How to correctly run protractor tests? ng e2e equal to protractor... something

Hey I have quick question, I've installed protractor, and I have this basic e2e folder in my Angular project. If I use command "ng e2e", will it build and run my tests inside e2e folder using protractor framework or will it run it without…
blackko2
  • 3
  • 2
0
votes
1 answer

Separate package.json for angular e2e tests?

I am using Angular 8 in my project. Is it possible to have a separate package.json file for e2e tests? I am using jest for unit testing and protractor+jasmine for e2e. Because of this, I can't completely remove jasmine from my package.json. And,…
mr__brainwash
  • 1,334
  • 3
  • 16
  • 40
0
votes
2 answers

Cypress testing list of items. Error on not getting any items?

I was wondering about this scenario: I have a list of records, list items, and i want to do something on the items. The problem is, that i believe that when i query the items, sometimes I might have zero items, and other times I won't. When i don't…