Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CAS Login not testable with cypress #4

Closed
p-a-s-c-a-l opened this issue Jan 29, 2020 · 5 comments
Closed

CAS Login not testable with cypress #4

p-a-s-c-a-l opened this issue Jan 29, 2020 · 5 comments
Assignees
Labels
bug Something isn't working question Further information is requested wontfix This will not be worked on
Milestone

Comments

@p-a-s-c-a-l
Copy link
Member

Upon login, CAS redirects to a different domain. Automatic redirect fails with:

Refused to display 'https://csis.myclimateservice.eu/' in a frame because it set 'X-Frame-Options' to 'sameorigin'

See also cypress-io/cypress#1506 and clarity-h2020/csis#122 (comment)

Manual redirect does not work either:

CypressError: cy.visit() failed because you are attempting to visit a second unique domain.
You may only visit a single unique domain per test.
Different subdomains are okay, but unique domains are not.
The previous domain you visited was: 'https://profile.myclimateservices.eu'
You're attempting to visit this new domain: 'https://csis.myclimateservice.eu'
You may need to restructure some of your code to prevent this from happening.
https://on.cypress.io/cannot-visit-second-unique-domain

@p-a-s-c-a-l p-a-s-c-a-l added bug Something isn't working question Further information is requested labels Jan 29, 2020
@p-a-s-c-a-l p-a-s-c-a-l added this to the CSIS Release milestone Jan 29, 2020
@p-a-s-c-a-l p-a-s-c-a-l self-assigned this Jan 29, 2020
@p-a-s-c-a-l p-a-s-c-a-l added this to To do in T1.4 Industrialization and Support via automation Jan 29, 2020
p-a-s-c-a-l added a commit that referenced this issue Jan 29, 2020
@p-a-s-c-a-l
Copy link
Member Author

Sessions not preserved among different tests:

grafik

@p-a-s-c-a-l
Copy link
Member Author

Visiting a different domain in another tests causes cypress to end up in an infinite loop:

cypress-havoc

@p-a-s-c-a-l
Copy link
Member Author

Visiting a different domain in another tests causes cypress to end up in an infinite loop:

Probably related to missing ${baseUrl}, see cypress-io/cypress-documentation#1154 ?

However, setting ${baseUrl} to https://csis.myclimateservice.eu results in the following warning:

Cypress could not verify that this server is running:
https://csis.myclimateservice.eu
This server has been configured as your baseUrl, and tests will likely fail if it is not running.

@p-a-s-c-a-l
Copy link
Member Author

Removing the baseUrl does not work. But visiting https://csis.myclimateservice.eu before https://profile.myclimateservices.eu does not lead to an infinite loop. ?! :hurtrealbad:

p-a-s-c-a-l added a commit that referenced this issue Jan 30, 2020
@p-a-s-c-a-l
Copy link
Member Author

p-a-s-c-a-l commented Jan 30, 2020

  • Setting the baseUrl programmatically instead of specifying it in cypress.json does not lead to to the 'Cypress could not verify that this server is running' error.
  • baseUrl can only be specified once per project. So overwriting the baseUrl in 020 will also change the base url of the 010 test spec.
  • Moving CSIS Tests to another specs file will still result in an infinite loop, too

@p-a-s-c-a-l p-a-s-c-a-l added the wontfix This will not be worked on label Jan 30, 2020
T1.4 Industrialization and Support automation moved this from To do to Done Jan 30, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working question Further information is requested wontfix This will not be worked on
Development

No branches or pull requests

1 participant