https://cypress.io logo
Join Discord
Powered by
# e2e-testing
  • m

    mammoth-judge-21605

    08/17/2022, 1:17 PM
    Hello, has anyone else noticed that since updating to Chrome 104. Longer e2e spec files seem to be hitting the out of memory exception. This is code that ran without an issue last week against Chrome 103. I've seen it logged here as an issue https://github.com/cypress-io/cypress/issues/23391. We've already got numTestsKeptInMemory set as 1. This out of memory issue seems to be happening more often as both Cypress and Chrome update
  • h

    handsome-lion-1748

    08/17/2022, 2:08 PM
    When using cy.log() where do I find the logged message?
  • m

    mammoth-judge-21605

    08/17/2022, 2:10 PM
    it shows up in the history on the left when using cypress open.
  • h

    handsome-lion-1748

    08/17/2022, 2:11 PM
    Cool, thanks @mammoth-judge-21605 I'll try
  • f

    fast-artist-45202

    08/17/2022, 2:12 PM
    If you're running headless, I'd recommend trying out
    cypress-terminal-report
    to get more visibility into anything that would normally go into the dev tools console
  • h

    handsome-lion-1748

    08/17/2022, 2:13 PM
    I can see it now
  • h

    handsome-lion-1748

    08/17/2022, 2:13 PM
    thanks for the suggestion @fast-artist-45202 I'll check it
  • f

    fast-artist-45202

    08/17/2022, 2:18 PM
    Is there an easy way for me to send a warning to console if an action takes longer than a specific amount of time, but only fail if it meets my default timeout? For example, clicking a button that increases quantity in cart, then asserting a change in the quantity #. - If the quantity # doesn't update within 2 seconds, warn in console. - If the quantity # doesn't update 6 seconds later (for 8 second global default timeout), fail test step
  • h

    handsome-lion-1748

    08/17/2022, 2:29 PM
    Is there an easy way for me to send a
  • v

    victorious-honey-34966

    08/17/2022, 2:32 PM
    you are right. currently, i don't see any solution coming from cypress
  • b

    blue-battery-71202

    08/17/2022, 3:08 PM
    Hi all, Currently, I'm trying to transfer our fw to Typescript from JS, which was working well until I did an npm update. Now, this is the issue I'm having. https://github.com/badeball/cypress-cucumber-preprocessor/issues/804 Has anyone encountered such an error, if so, how did you resolve it? Also - I am starting an integration test with
    *.ts
    and not`*.feature`. I doubt that any Before hook from
    stepDefinitions
    folder should interrupt that run. Cucumber scenarios start correcly, and it reads everything as expected. Only
    .ts
    cannot be started with such error. Thanks !
  • s

    sparse-piano-30763

    08/17/2022, 3:47 PM
    Uhm... I have another doubt related to my original problem... Why Cypress tries to run. the second try after the initial try run all the tests? By looking at the Cypress Run screenshot shared in the official docs https://docs.cypress.io/guides/guides/test-retries#How-It-Works it should retry the failing test immediately after a single test failure...
  • m

    microscopic-crowd-9149

    08/17/2022, 5:26 PM
    Hey Friends - i did setup AWS codebuild to run test automatically every night. schedule working fine but i found that website speed is super slow & cypress time out on few steps. Any suggestions how we can improve this ( i am running same process locally in day everything works fine )
    f
    • 2
    • 1
  • f

    fancy-dog-10840

    08/17/2022, 6:28 PM
    Hi All. I recently upgraded to the the new version and I am having issues with the cypress-drag-drop plugin. In the previous version, my scripts were able to drag fields onto a document image, but now the fields are not longer being being applied. Are there any tips that I can try?
  • a

    acceptable-solstice-90676

    08/17/2022, 8:24 PM
    Does anybody know how to clear cache in the after all...it seems
    cy.clearCookie()
    doesn't work on
    before
    not
    after
    , it only works on
    beforeEach
    and
    afterEach
  • b

    breezy-hydrogen-39214

    08/17/2022, 9:46 PM
    Anyone have experience looping through links in a table?
  • n

    nutritious-honey-65632

    08/17/2022, 9:51 PM
    what is the problem?
  • b

    breezy-hydrogen-39214

    08/17/2022, 9:53 PM
    When I try looping through all the elements it goes through once and then says the element isn’t attached to the DOM
  • h

    handsome-lion-1748

    08/18/2022, 7:37 AM
    I had such a problem in webdriver.io before, I think you should select the elements again in every iteration
  • h

    handsome-lion-1748

    08/18/2022, 7:37 AM
    and by the way as I read in the cypress intro, you shouldn't loop but you should do recursion
  • b

    blue-battery-71202

    08/18/2022, 9:19 AM
    anyone has experience with
    cy.origin()
    ? I have a test case where I do a sort of login in
    beforeEach
    and then in the test case I navigate with
    /customRoute
    where customRoute is a string to a page on the site, but it seems to navigate me back to login. In 9.6 it worked, yesterday I upgraded to 10.x and now its not.
  • b

    blue-battery-71202

    08/18/2022, 10:06 AM
    Turns out cypress loses cookies after cy.origin, how to keep all cookies in that case?
  • a

    acceptable-hamburger-48790

    08/18/2022, 10:16 AM
    Did you check this https://docs.cypress.io/api/commands/session
  • b

    blue-battery-71202

    08/18/2022, 10:26 AM
    I am just checking it, I can't seem to restore cookies. Here's the scenario: BeforeEach test I click on the UI to "login".. After that, in the test case, I just restore the session, and visit the page > then use the cy.visit(/route) to navigate to a different page. Unfortunately, cookies are lost at that point, or never restored.
  • b

    blue-battery-71202

    08/18/2022, 10:32 AM
    Copy code
    ts
    BeforeEach(() => {
      cy.session('session', () => {
        cy.login();
      });
    });
    
    it(('asd'), () => {
     cy.session('session', () => {
       cy.login();
     });
    
      cy.origin(('https://randomPage.com') => {
        cy.visit('/users');
      });
      checkElementsOnUsers();
    });
  • b

    blue-battery-71202

    08/18/2022, 10:32 AM
    checkElementsOnUsers should have stored cookies, and on the randomPage.com/users url.
  • w

    white-raincoat-83199

    08/18/2022, 10:35 AM
    I got the same issue. after
    it('login', () => { login(); })
    finish about 300ms, cookies are lost.
  • b

    blue-battery-71202

    08/18/2022, 10:36 AM
    I'm pretty sure we use it wrong, I expect someone uses it, and knows how to do it properly, and maybe can explain to us? ^^
  • b

    blue-battery-71202

    08/18/2022, 10:57 AM
    ok I figured it out @white-raincoat-83199, whats your case?
  • b

    blue-battery-71202

    08/18/2022, 10:58 AM
    if the same as me, just remove cy.origin and just use cy.visit with the whole url
1...838485...192Latest