powerful-orange-86819
02/18/2022, 12:07 PMglamorous-architect-52545
02/18/2022, 12:26 PMclean-wire-62738
02/18/2022, 4:40 PMadventurous-dream-20049
02/18/2022, 7:46 PMclean-wire-62738
02/19/2022, 8:32 AMadventurous-dream-20049
02/22/2022, 12:14 AMwhite-agent-38646
02/22/2022, 6:38 PMmelodic-apple-72412
02/23/2022, 3:22 PM/ now any cookie with the name 'session_id' or 'remember_token'
// will not be cleared before each test runs
Cypress.Cookies.defaults({
whitelist: ['session_id', 'remember_token']
})
2. Use sessions.
Currently in our test, we just starting using session. But it needs to be called in beforeEach hook and if the session is active it will restore.
My question is isn't it faster to whitelist cookies rather using sessions?modern-king-58112
02/23/2022, 6:45 PMmodern-autumn-20651
02/23/2022, 10:32 PMgray-kilobyte-89541
02/24/2022, 12:42 PMfaint-spring-80499
02/24/2022, 6:54 PMbroad-potato-69393
02/24/2022, 11:46 PMbroad-potato-69393
02/28/2022, 1:39 AMadorable-smartphone-87280
02/28/2022, 5:10 AMsession()
is intended to be the default login style in a future version of Cypress.broad-potato-69393
02/28/2022, 5:35 AMpolite-alarm-78904
02/28/2022, 9:17 AMbroad-potato-69393
02/28/2022, 5:31 PMpolite-alarm-78904
03/01/2022, 1:04 PMgray-kilobyte-89541
03/01/2022, 3:11 PMmillions-spoon-12901
03/03/2022, 5:35 PMproud-piano-89169
03/04/2022, 5:47 PM"baseUrl": "."
and therefore all my imports look like import Button from "components/Button
. When I run a unit test and import a function from a file that includes other imports in that format, Cypress throws an error that looks like Error: Webpack Compilation Error
./utils/someMath.ts
Module not found: Error: Can't resolve 'utils/addTwoNumbers' in '/Users/bradycaspar/code/test/cypress-next/utils'
resolve 'utils/addTwoNumbers' in '/Users/bradycaspar/code/test/cypress-next/utils'
Parsed request is a module
using description file: /Users/bradycaspar/code/test/cypress-next/package.json (relative path: ./utils)
Field 'browser' doesn't contain a valid alias configuration
Looked for and couldn't find the file at the following paths:
[/Users/bradycaspar/code/test/cypress-next/utils/node_modules]
[/Users/bradycaspar/code/test/node_modules]
[/Users/bradycaspar/code/node_modules]
[/Users/node_modules]...
Not sure if there's some basic config I'm missing, any help would be appreciated! I created a minimal reproduction here: https://github.com/bscaspar/cypress-next-import-error-examplebulky-table-27118
03/06/2022, 9:08 PMbulky-table-27118
03/06/2022, 9:08 PMts
it('should be select birth data', () => {
cy.visit('/datepicker')
const date = {
month: 'nov',
year: '1984',
day: '30'
}
cy.get('.datetimepicker-dummy-input').click()
cy.get('.datepicker-nav-month').click()
cy.contains('.datepicker-month', date.month).click()
cy.get('.datepicker-nav-year').click()
cy.contains('.datepicker-year span', date.year).click()
cy.contains('button[class=date-item]', new RegExp('^' + date.day + '$', 'g')).click()
});
powerful-orange-86819
03/07/2022, 12:12 PMbulky-table-27118
03/07/2022, 12:19 PMmodern-king-58112
03/07/2022, 5:33 PMmodern-king-58112
03/07/2022, 5:41 PMpowerful-orange-86819
03/08/2022, 12:26 PMmodern-king-58112
03/08/2022, 7:59 PM