wonderful-match-15836
07/09/2021, 3:00 PMcy.window().then((win) => {
console.log(win); // I can't see the global when I inspect this object
console.log(win.__testProp__); // but sure enough I can access it
});
It took me a second to realize the problem - in my case, when the test completes, an afterEach
runs that navigates back to a starting page and logs out. So by the time I expand that object in the console and it gets evaluated, window
is a different page that never set the globals. If I put a cy.pause()
after the console log so the test stays put while I inspect the logs, I was able to see that my __testProp__
was indeed part of the window object.dazzling-gold-63692
07/09/2021, 3:53 PMfaint-bear-92677
07/10/2021, 6:51 PMdazzling-gold-63692
07/11/2021, 10:19 PMlittle-truck-20143
07/12/2021, 1:13 AMfaint-bear-92677
07/13/2021, 2:48 AMbest-yacht-92435
07/13/2021, 3:12 PMbrief-kite-35331
07/14/2021, 8:49 PMmodern-nail-49491
07/15/2021, 4:49 PMuser
07/16/2021, 10:30 AMRegion
but I need to have one Region
and all tests should be inside Region
. How can I do this?ancient-wire-34126
07/16/2021, 1:12 PMancient-wire-34126
07/16/2021, 1:13 PMdotenv
comes out of nowhere for exampleancient-wire-34126
07/16/2021, 1:14 PMancient-wire-34126
07/16/2021, 1:16 PMancient-wire-34126
07/16/2021, 2:12 PMuser
07/16/2021, 3:40 PM├── cypress
│ ├── cypress.json
│ ├── fixtures
│ ├── integration
│ ├── plugins
│ ├── screenshots
│ └── support
when running within CI I'm getting error from Cypress:
We looked but did not find a cypress.json file in this folder: /e2e
I'm using containerized Cypress:
docker run -v $PWD:/cypress -w /e2e --network tdd_default cypress/included:7.7.0
What am I doing wrong ?bulky-sundown-74498
07/16/2021, 3:40 PMbulky-sundown-74498
07/16/2021, 3:41 PMbulky-sundown-74498
07/16/2021, 3:41 PMbulky-sundown-74498
07/16/2021, 3:42 PMbulky-sundown-74498
07/16/2021, 3:43 PMbulky-sundown-74498
07/16/2021, 3:43 PMuser
07/16/2021, 3:48 PMuser
07/16/2021, 4:04 PMcypress.json
one level up. I wonder if I can just run ls
within the environment to see if the file is even present where I expect it.bulky-sundown-74498
07/16/2021, 4:05 PMbulky-sundown-74498
07/16/2021, 4:06 PMbulky-sundown-74498
07/16/2021, 4:06 PMuser
07/16/2021, 4:11 PMnode_modules/.bin/cypress run --config-file cypress-dev.json
and that runs. But now I downloaded containerized Cypress and it gives me the same error. The only difference between cypress-dev.json
and cypress.json
is the baseUrl
value. Which is different for CI environment.bulky-sundown-74498
07/16/2021, 4:11 PMbulky-sundown-74498
07/16/2021, 4:11 PM