sparse-electrician-28646
10/26/2022, 6:56 AMexperimentalSessionAndOrigin and it enables the stricter test isolation. That works as expected.
We also have custom commands and I need them to be available in the origin callback. Luckily the documentation also has a section for that: https://docs.cypress.io/api/commands/origin#Custom-commands
So I followed that advice and added this to the spec:
before(() => {
cy.origin('http://secondorigin', () => {
require('../../support/commands')
})
})
But the test fails with:
"before all" hook for "test case name":
cypress_1 | ReferenceError: __webpack_require__ is not defined
So it seems the require function cannot be resolved for some reason. Does anyone have a clue why? I'd be very happy about any kind of direction how to further debug this