clicking on href in cypress incognito mode is shortened the url #22298
Unanswered
tuimai
asked this question in
Questions and Help
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
If I click on an href in cypress in incognito mode, the url opens without a subdirectory. Cypress deletes everything that comes after /.
this is the code i used to open in incognito:
module.exports = (on, config) => {
//
on
is used to hook into various events Cypress emits//
config
is the resolved Cypress configon("before:browser:launch", (browser, launchOptions) => {
console.log(launchOptions.args);
if (browser.name === "chrome") {
launchOptions.args.push("--incognito");
}
return launchOptions;
});
};
Beta Was this translation helpful? Give feedback.
All reactions