crooked-television-64942
05/17/2021, 7:24 AMgray-kilobyte-89541
05/17/2021, 12:14 PMmany-jackal-86011
05/17/2021, 1:16 PMmany-jackal-86011
05/17/2021, 1:16 PMmany-jackal-86011
05/17/2021, 1:18 PMcrooked-television-64942
05/17/2021, 2:12 PMrequire('cypress-grep')()
to support/index.js
2 - add require('cypress-grep/src/plugin')(config)
in module.exports from plugins/index.js
3 - add describe('test name', { tags: 'fast' }, () => {
in a single test as example
4 - run npx cypress run --env grepTags=@fast
for the example
the output said: found 93 tests (that's all tests)user
05/17/2021, 3:50 PMgray-kilobyte-89541
05/17/2021, 8:23 PM.only
itcrooked-television-64942
05/17/2021, 8:28 PMbillowy-spoon-30011
05/18/2021, 8:27 AMglamorous-byte-70077
05/18/2021, 3:56 PMuser
05/18/2021, 8:30 PMDate
object? e.g. const now = new Date()
?billowy-spoon-30011
05/18/2021, 8:34 PMstocky-dream-36427
05/19/2021, 12:12 AMstocky-dream-36427
05/19/2021, 12:12 AMbillowy-spoon-30011
05/19/2021, 9:18 AMlimited-keyboard-75773
05/19/2021, 4:08 PMnpx cypress run --record --key <key-goes-here>
, however this runs the entire suite. I tried npx cypress run --record --key <key-goes-here> --CYPRESS.spec="cypress/integration/path/to/file/*.spec.js"
but I dont' get it to work. Any ideas what I am doing wrong?limited-keyboard-75773
05/19/2021, 4:16 PM--CYPRESS.spec="cypress/integration/path/to/file/*.spec.js"
to --spec="cypress/integration/path/to/file/*.spec.js"
bumpy-toddler-47155
05/19/2021, 7:59 PMbulky-sundown-74498
05/19/2021, 8:46 PMbulky-sundown-74498
05/19/2021, 8:48 PMdbSeed().then(dataset => {do something with your dataset})
dazzling-gold-63692
05/20/2021, 3:30 PMbumpy-toddler-47155
05/20/2021, 7:14 PMflat-electrician-52949
05/20/2021, 7:45 PMts
cy.get('button').contains('ADD TO CART').click()
cy.get('#state').invoke('text').then(JSON.parse).as('state')
cy.get('@state').then((cartState) => {
const expectedCartState: TCartItem[] = [{ ...order, quantity: 1 }]
expect(cartState).to.deep.eq(expectedCartState)
})
cy.get('button').contains('ADD TO CART').click()
cy.get('@state').then((cartState) => {
const expectedCartState: TCartItem[] = [{ ...order, quantity: 2 }]
expect(cartState).to.deep.eq(expectedCartState)
})
flat-electrician-52949
05/20/2021, 7:46 PMcy.get('#state').invoke('text').then(JSON.parse).then(..assertion)
on every assertionstocky-dream-36427
05/20/2021, 7:55 PMstocky-dream-36427
05/20/2021, 7:55 PMflat-electrician-52949
05/20/2021, 7:57 PMconst assertState = (assertion) => cy.get('#state').invoke('text').then(JSON.parse).then(assertion())
flat-electrician-52949
05/20/2021, 7:58 PM