brash-mechanic-5372
08/22/2022, 10:00 PMabundant-hydrogen-26466
08/22/2022, 10:01 PM"
around the id as wellbrash-mechanic-5372
08/22/2022, 10:02 PMabundant-hydrogen-26466
08/22/2022, 10:02 PMbrash-mechanic-5372
08/22/2022, 10:05 PMabundant-hydrogen-26466
08/22/2022, 10:05 PMbrash-mechanic-5372
08/22/2022, 10:47 PMabundant-hydrogen-26466
08/22/2022, 10:48 PMbrash-mechanic-5372
08/22/2022, 10:49 PM./node_modules/.bin/cypress open
brash-mechanic-5372
08/22/2022, 10:50 PMabundant-hydrogen-26466
08/22/2022, 10:53 PMshy-scientist-68278
08/22/2022, 10:59 PMbrash-mechanic-5372
08/22/2022, 11:00 PMbrash-mechanic-5372
08/22/2022, 11:04 PMbrash-mechanic-5372
08/22/2022, 11:10 PMabundant-hydrogen-26466
08/22/2022, 11:17 PMgentle-dress-1046
08/23/2022, 8:13 AMconst setBaseUrl = () => {
const appEnv = Cypress.env('app_env');
if (!appEnv) {
throw new Error("must set environment variable 'app_env' to one of the followings: local, preview, london, paris ");
}
if (appEnv === 'preview') {
const previewBaseUrl = Cypress.config().baseUrl;
if (!previewBaseUrl) throw new Error('you must set a baseURL when running tests on preview mode!');
} else if (appEnv === 'local' || appEnv === 'london' || appEnv === 'paris') {
const baseUrl = getBaseUrlObject(appEnv).appUrl;
Cypress.config('baseUrl', baseUrl);
} else {
throw new Error(`unknown testing environment: ${appEnv}`);
}
};
before(() => {
setBaseUrl();
cy.reload();
});
I want to config this before the tests, because this way is acting weird, is there a way to configure it before everything?great-furniture-24480
08/23/2022, 8:33 AMbaseUrl
there. Now in your pipeline, add env
in following script env:
CYPRESS_baseUrl: http://localhost
CYPRESS_RECORD_KEY:
and add your environment there. you will have a different workflow for each environment so you can here for testing, staging and live.adventurous-afternoon-89751
08/23/2022, 10:33 AMURL: https://download.cypress.io/desktop/9.2.1?platform=linux&arch=x64
Error: Failed downloading the Cypress binary.
Response code: 403
Response message: Forbidden
i am behind tor
i think this means your CDN is just unilaterally blocking tor users from installing cypress in the documented way, which, if true, seems pretty malicious and i would appreciate it if you could reconfigure.fresh-winter-92619
08/23/2022, 12:11 PMfancy-airplane-60156
08/23/2022, 12:30 PMfancy-airplane-60156
08/23/2022, 12:30 PMfreezing-wall-5568
08/23/2022, 1:13 PMgentle-dress-1046
08/23/2022, 2:40 PMgentle-dress-1046
08/23/2022, 3:53 PMcy.visit('/', {
onBeforeLoad: () => {
clearCache();
},
});
but it seems like it delete the indexDbgentle-dress-1046
08/23/2022, 3:55 PMfresh-winter-92619
08/23/2022, 4:02 PMabundant-hydrogen-26466
08/23/2022, 4:39 PMwindow
object that is actually different than the object referenced when a static window
call is made. I would try...
export const clearIndexDb = () => {
cy.window().then((window) => {
window.indexedDB.deleteDatabase('session');
})
};
and see if that resolves the issue for you.
Further reading here --> https://docs.cypress.io/api/commands/windowchilly-telephone-39196
08/23/2022, 4:41 PM