https://cypress.io logo
Join Discord
Powered by
# help
  • m

    magnificent-finland-58048

    01/11/2023, 7:57 PM
    that's it right, it's very hard to diagnose those plugin and task failures you can configure cypress tsconfig independent of the top level tsconfig that repo has an example, but here are CRA and vite templates with TS, prettier, eslint, cypress, GHA etc etc. https://github.com/muratkeremozcan?tab=repositories&q=template&type=&language=&sort=
    c
    • 2
    • 2
  • m

    magnificent-finland-58048

    01/11/2023, 8:01 PM
    you might need to turn off that experimental flag @few-farmer-48800 you ran into it , what was it? without it, you might need to enhance some of that test code to start using cy.session, but doesn't sound like you want exactly that with the tests
  • f

    full-helmet-93291

    01/11/2023, 8:07 PM
    Thanks @magnificent-finland-58048 , Which experimental flag are you referring to?
  • f

    few-farmer-48800

    01/11/2023, 8:10 PM
    That's it
  • f

    few-farmer-48800

    01/11/2023, 8:11 PM
    If you're doing that you need to add in testIsolation: false to your config
  • f

    full-helmet-93291

    01/11/2023, 8:15 PM
    Thanks @few-farmer-48800 I've already tried that prior to posting the question and it doesn't work either. Sorry for not putting it before
  • f

    full-helmet-93291

    01/11/2023, 8:16 PM
    I've posted my question here https://github.com/cypress-io/cypress/discussions/25437 FYI
  • c

    cool-truck-21040

    01/11/2023, 8:19 PM
    that s it right it s very hard to
  • m

    magnificent-finland-58048

    01/11/2023, 8:27 PM
    hmm , difficult to say anything without looking at reproducible code, but it might be forcing to do things the cy.session way now
  • m

    magnificent-finland-58048

    01/11/2023, 8:27 PM
    take a look at https://github.com/muratkeremozcan/auth0-cypress/blob/master/cypress/support/commands.js
  • f

    full-helmet-93291

    01/11/2023, 8:29 PM
    thank you @magnificent-finland-58048 will do 🙂
  • f

    few-farmer-48800

    01/11/2023, 8:54 PM
    I guess I did mis-read a little bit
  • f

    few-farmer-48800

    01/11/2023, 8:54 PM
    You log in and logout after every test?
  • f

    few-farmer-48800

    01/11/2023, 8:54 PM
    If so, maybe that's the difference. We log in once and maintain that state
  • v

    victorious-monkey-77957

    01/11/2023, 10:53 PM
    How do test update functionality on cypress?
    Copy code
    it.only('sends ticket to completed by pressing title',()=>{
          cy.intercept({
            method: 'GET',
            url: 'some secret url lol'
          },{
            fixture: 'activeTickets.json'
          });
          cy.get('[data-test="activeTicketsCollection"]').should('be.visible');
          cy.contains('ChiChi K.').should('be.visible').click();
    
          cy.intercept({
            method: 'PATCH',
          }, {fixture: 'activeToComplete.json'}).as('updatedList');
          cy.wait('@updatedList').then(({response}) => {
            expect(response.body).to.have.length(2);
          });
    im using fixtures to bring in an "active list". upon clicking it listen for the patch request . then should i bring in a seperate fixture for 'update' ? And how do i get the new fixture to show on my ui? or am I doing this wrong all together?
  • g

    gray-kilobyte-89541

    01/12/2023, 12:02 AM
    You are doing it wrong. https://glebbahmutov.com/blog/cypress-intercept-problems/#the-intercept-was-registered-too-late
  • s

    some-keyboard-52751

    01/12/2023, 12:43 AM
    i am getting memory issue how to fix that issue
  • m

    magnificent-lamp-44201

    01/12/2023, 2:06 AM
    Create a mock server I need guidance on an assessment I need to do (screenshot attached). As I understand, I need to create a mock server and then test it. Checking on Internet how to create the mock server, I found this: https://www.mocks-server.org/docs/integrations/cypress/ , but being honest I don't understand how to use it. I was trying to figure out how to configure it and use it, but no success. Also I was searching for samples on Internet, but the only sample is the existing documentation of the library. Documentation is not clear for me. I haven't done mock servers in the past, and I'm totally confused with this. Is there any other way to do this? Can someone help/guide me? Thanks in advance for your help, guys.
  • s

    some-keyboard-52751

    01/12/2023, 2:14 AM
    hi I wrote loop condition while I am running test cases i getting out of memory issue
  • h

    handsome-businessperson-71907

    01/12/2023, 1:58 PM
    Hello I'm trying to migrate from cypress v8.3 to cypress v10+, the migration tool didn't work at first so I had start from scratch and update it manually so I might have missed something, here's my error, anyone encountered this before? Thanks in advance!
  • h

    handsome-businessperson-71907

    01/12/2023, 2:06 PM
    removing defineConfig wrapper did the work, although it will remove cypress code completion or so it says here https://docs.cypress.io/guides/references/configuration#Intelligent-Code-Completion
  • f

    few-oyster-82478

    01/12/2023, 2:07 PM
    Hi, our pipeline has started to fail giving this error message (it was working fine before with the same config):
    Copy code
    The run you are attempting to access is already complete and will not accept new groups.
    The existing run is: https://cloud.cypress.io/projects/naz8rj/runs
    When a run finishes all of its groups, it waits for a configurable set of time before finally completing. You must add more groups during that time period.
    The --tag flag you passed was: development
    The --group flag you passed was: firefox
    The --parallel flag you passed was: true
    https://on.cypress.io/already-complete
    not sure what it means by
    you must add more groups during that time period
    groups are defined this way in the
    package.json
    Copy code
    "cy:run:chrome": "cypress run --browser chrome --group chrome",
    "cy:run:firefox": "cypress run --browser firefox --group firefox",
    Our current Run completion delay is set to 60s, but not sure if it would help changing it And this is the config for the failing gitlab-ci job:
    Copy code
    e2e_development_firefox:
      image: cypress/browsers:node16.16.0-chrome107-ff107-edge
      stage: e2e
      parallel: 2
      needs: [deploy]
      only:
        - merge_requests
      script:
        - $(npm bin)/cypress cache path
        - $(npm bin)/cypress cache list
        - $(npm bin)/cypress verify
        - npm run cy:run:firefox -- --tag development --key <key> --record --parallel --config baseUrl=${DYNAMIC_ENVIRONMENT_URL}
  • f

    few-oyster-82478

    01/12/2023, 2:43 PM
    so in the end the solution was to use the group option inside the gitlab ci stages instead of the package.json scripts
  • h

    handsome-businessperson-71907

    01/12/2023, 3:52 PM
    in my package.json
    Copy code
    "cypress-cucumber-preprocessor": {
        "nonGlobalStepDefinitions": true,
        "stepDefinitions": "src/integration/**/*.{js,ts}"
      }
    is there a way to isolate step definitions, for example the feature file in
    integration/feature1.feature
    uses the step definition in:
    integration/feature1/testFile.ts
  • q

    quick-tomato-75303

    01/12/2023, 4:11 PM
    Hi all! This is a silly one, I couldn't find about though: setting the corresponding value to DEBUG variable as an admin in macOS does not seem have any effect in the subsequent headless run of my tests (no extra messages are printed). I'm on Cypress 9.5.0, BTW. Thanks!
  • f

    freezing-piano-2792

    01/12/2023, 4:20 PM
    https://github.com/badeball/cypress-cucumber-preprocessor/blob/master/docs/step-definitions.md#pairing-explained
  • b

    bright-twilight-69276

    01/12/2023, 5:48 PM
    Question for you, does Cypress clear cookies between each it{} block?
  • g

    gray-kilobyte-89541

    01/12/2023, 6:05 PM
    https://docs.cypress.io/guides/core-concepts/test-isolation#What-is-Test-Isolation
  • m

    modern-glass-50699

    01/12/2023, 7:36 PM
    Solved the basicAuth issue after 2 weeks of brain pain 😄 maybe someone will find this interesting: turns out i needed to add 'www.' to my baseUrl. The difference in basic auth on a domain with 'www.' and without it is likely due to the way the website's server is configured. The server administrator may have set up different authentication settings for the 'www' version of the domain and the non-www version.
  • f

    flaky-sunset-93931

    01/12/2023, 8:52 PM
    Hey there! I added Cypress to my docker-compose. I've rebuilt my container, but I seem to running into an issue where I can never get the image to run. There are no logs either
1...248249250251252Latest