https://cypress.io logo
Join DiscordCommunities
Powered by
# e2e-testing
  • f

    full-lighter-7311

    01/05/2023, 3:20 PM
    My team doesn't want me to use it lol
  • m

    mysterious-psychiatrist-29678

    01/05/2023, 3:22 PM
    hi again. happy new year. I'm facing a problem with login. in beforeEach hook I authenticate and visit a page then actual testing comes. 3 of 4 test cases run flawlessly, but the last one in 50-60% fail at beforeEach however the same code runs as at the other passing tests. could you give me some hint what to check? I use session not to login at every test and seems session restoration fails.
  • h

    handsome-businessperson-71907

    01/05/2023, 3:22 PM
    yikes, well I guess your front is not something as simple as a
    <a href="/">Text</a>
    try inspecting the element and click on the link yourself, see if anything other than you tag pops up
  • f

    full-lighter-7311

    01/05/2023, 3:30 PM
    Nothing pops up. This is the component
  • f

    full-lighter-7311

    01/05/2023, 3:32 PM
    Got it. I need to hover an element in order to show the element I want to click
  • f

    full-lighter-7311

    01/05/2023, 3:33 PM
    The element I'm trying to click is rendered on the DOM but it is hidden
  • f

    full-lighter-7311

    01/05/2023, 3:34 PM
    https://stackoverflow.com/questions/68545799/mouseover-in-cypress
  • f

    full-lighter-7311

    01/05/2023, 3:34 PM
    I guess I'll need something like this
  • b

    best-flower-17510

    01/05/2023, 3:57 PM
    Hey @ambitious-kite-44982 did you submit a issue regarding your question? - https://github.com/cypress-io/cypress/issues/new/choose
  • a

    ambitious-kite-44982

    01/05/2023, 4:04 PM
    https://github.com/GoogleChrome/lighthouse/issues/3024
  • n

    nice-lifeguard-81070

    01/06/2023, 6:57 AM
    hey can anyone help me how can I add codecov github action for cypress code coverage in nuxt3 ?
  • s

    straight-spoon-64191

    01/06/2023, 9:41 AM
    Hi guys, is it possible to get some code snippets connecting to a MS Sql database using Cypress 12.3.0? I've seen many articles using older Cypress versions which includes the deprecated folders such as cypress.json and index.js (cypress/support)
  • m

    mysterious-psychiatrist-29678

    01/06/2023, 1:25 PM
    how would you solve the issue if by clicking a button the backend sends the response, what I'm waiting for, earlier than the script actually starts to intercept. on the picture you can see the script already clicked the button, got to the next page, but still waiting for the response to arrive that never arrive again obviously. anyway rendering the next page takes a couple of secs from the time the button has been clicked. here it comes the code
    Copy code
    Cypress.Commands.add('moveForward', () => {
    cy.contains('[role="button"]', 'Next')
        .click()    
    cy.intercept({
          url: 'https://management.azure.com/batch?api-version=2020-06-01',
          headers: {
            'x-ms-command-name': '{ Microsoft_Azure_CreateUIDef.BatchNextTick:0,GetSubRGs.-1:1,Services.ArmLocations.getLocForResTypes.-1:16}'
          }
        }).as('reponseFromBackend')
     cy.wait('@reponseFromBackend', {timeout: 10000})
    })
  • b

    bitter-fountain-36713

    01/06/2023, 2:26 PM
    !duplicate
  • n

    nutritious-analyst-96582

    01/06/2023, 2:26 PM
    Uh oh, It looks like you have posted the same question in multiple channels. Help us prevent spam by removing any duplicates of your questions, Thanks! ๐Ÿ˜€
  • b

    bitter-fountain-36713

    01/06/2023, 2:27 PM
    Move your intercept before the test does the click.
  • m

    mysterious-psychiatrist-29678

    01/06/2023, 2:30 PM
    I did to no avail
  • b

    bitter-fountain-36713

    01/06/2023, 2:31 PM
    Ah, I just looked at it again. Are looking to intercept
    /api/Telemetry
    ?
  • m

    mysterious-psychiatrist-29678

    01/06/2023, 2:39 PM
    no I look the one is just out of the window above "test body"
  • b

    bitter-fountain-36713

    01/06/2023, 2:47 PM
    Ah, its always good to have the intercept before it happens.. So if you move it before before it should catch it and then you can wait for it.
  • m

    mysterious-psychiatrist-29678

    01/06/2023, 2:48 PM
    I concluded the same but didn't help
  • p

    polite-painting-51763

    01/06/2023, 3:27 PM
    Any idea why we get this error? And how to get rid of it?
  • m

    mysterious-psychiatrist-29678

    01/06/2023, 3:53 PM
    hi again happy new year
  • g

    gray-kilobyte-89541

    01/06/2023, 4:16 PM
    https://github.com/cypress-io/cypress/issues/25078
  • h

    hallowed-translator-47432

    01/06/2023, 6:36 PM
    is there any reason why cypress would be caching my spec files. I have a Vue3 Vite app, and when i edit my spec file, cypress is watching and re-runs my tests, but none of the tests are updated, as if the spec was cached. what is going on?
  • b

    bored-van-76450

    01/07/2023, 5:30 AM
    Hello here, I am having some challenges in my automation testing using cypress. The challenge is with handling a new browser tab as cypress doesnโ€™t support it. My research found a method which affects html elements with attribute target = _blank. But the website of my am testing does not use this on the link/site that am working on. Secondly, is loading a new extension unto the system. I found a way to load it unto cypress but I am having a challenge loading up the cypress dashboard. Thirdly, is to make cypress interact with the extension. My research only let me see way to load the extension unto cypress, not to have cypress use the extension. Can anyone here assist with these challenges please?
  • p

    purple-afternoon-2408

    01/07/2023, 10:41 AM
    Hello everyone, I really need stop cypress from stopping tests due to a script error that's not related to page functionality:
    Copy code
    Cypress detected that an uncaught error was thrown from a cross origin script
    This error is from a third party plugin however, it does not break the page.
  • c

    cool-planet-811

    01/07/2023, 6:31 PM
    ๐Ÿ‘‹ Hi everyone! I'm trying to use cypress to login on duolingo to fetch some statistics using the following script
    Copy code
    describe("template spec", () => {
      it("should login", () => {
        cy.visit("https://www.duolingo.com/");
        cy.get("#onetrust-accept-btn-handler").click();
        cy.get('button[data-test="have-account"]').click();
        cy.get('input[data-test="email-input"]').type(USERNAME);
        cy.get('input[data-test="password-input"]').type(PASSWORD);
        cy.wait(3000);
        cy.get('button[data-test="register-button"]').click();
      });
    });
    But when I run it, I get the following error
    Copy code
    (uncaught exception)Error: Script error. Cypress detected that an uncaught error was thrown from a cross origin script. We cannot provide you the stack trace, line number, or file where this error occurred. Check your Developer Tools Console for the actual error - it should be printed there. It's possible to enable debugging these scripts by adding the crossorigin attribute and setting a CORS header.
    And I get nothing in the console. I tried on FF and Chrome, tried to disable web security and some other things, nothing works... Any idea, tips?
  • c

    clean-processor-42509

    01/07/2023, 8:18 PM
    How to run cypress tests in parallel without a dashboard locally and CI (Bamboo)?
  • g

    gifted-vase-76896

    01/08/2023, 4:39 AM
    Hey @late-planet-4481 my guess is that this site is filtering to only allow IPs from certain countries. What country are you in out of curiosity?
1...181182183...192Latest