bahmutov / cypress-v10-preserve-cookie

Cypress.Cookies.preserveOnce for Cypress v10
MIT License
7 stars 2 forks source link

Not able to use this with cucumber cypress framework #6

Open radhakrishnanakireddy opened 2 years ago

radhakrishnanakireddy commented 2 years ago

Thanks for the plugin, but I am trying to use this in @bahmutov/cypress-esbuild-preprocessor, but I am not able to store the session cookie and reuse it or I might be doing wrong I am doing like below import "cypress-v10-preserve-cookie";

import loginPage from "../../../support/modules/ui/login/loginPage"; before(() => { cy.log("START TESTS");

loginPage.login("xxxx", "xxxx"); });

beforeEach(() => { // equivalent to cy.preserveCookieOnce('connect.session') cy.preserveCookieOnce("connect.session"); });

Could you please help me with it

bahmutov commented 2 years ago

Have you tried looking at the debug logs? https://github.com/bahmutov/cypress-v10-preserve-cookie#debugging