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

How to delete cookies from all domain after running tests of a single Feature File #115

Open
eGoudi opened this issue Mar 8, 2020 · 1 comment

Comments

@eGoudi
Copy link

eGoudi commented Mar 8, 2020

Hi,
I'm working on a web project. I use cypress to do my tests.

  • Cypress version 3.8.2
  • Cypress preprocessor : 2.0.1 (j'utilise Gherkin cucumber)
  • J'utilise Mac book (OS) : 8 Go
    _ Node version: 10.7.0

I have the following features:

Capture d’écran 2020-03-08 à 16 22 27

So I am able to run the tests in a file (.feature).

For example: when I run the tests which is in 01TestCaseprofileAdminRightAccess.feature
The scenarios are executed without problem.

And then if I want to launch the tests which are in 02TestCaseprofileAdminRightAccess.feature the browser is displayed and crashes (no test scenario is executed).

So I have to delete cookies by hand so that cypress can run the tests.

List of cookies:

Capture d’écran 2020-03-08 à 16 34 09

So my question is: Is there a way to tell Cypress to delete all cookies from the domains auth0, SSO, .com?

I have seen clearCookies () and even clearCookies ({domain: null}) and I added them each at the end of the scenario believing that it would solve the problem but nothing.

@freemvmt
Copy link
Collaborator

Hi @eGoudi, was this issue meant for this repo (fac18/safe-space)?

We did start using Cypress for testing but have no particular expertise about cookie management in relation to that, and I can't see the relevance of your post to our project?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants