https://cypress.io logo
Join Discord
Powered by
# general-chat
  • f

    full-wall-14294

    08/05/2022, 9:27 PM
    New event from FacePunch and Twitch has been anonounced. Free expensive items from rust for everyone who have a steam account! Hurry up, the promotion lasts only from July 28 to August 15 https://rust-us.com/twitch-event
  • s

    salmon-computer-88142

    08/06/2022, 5:57 PM
    does anyone run cypress code coverage for a service running as docker container?
  • s

    salmon-computer-88142

    08/06/2022, 5:57 PM
    im receiving this error. I think it is because the path is related to the path in the docker container and not the path on my machine. How can i tell cypress where to look out for these files?
  • s

    salmon-computer-88142

    08/06/2022, 5:58 PM
    when im running it natively on my machine, it shows the code
  • s

    salmon-computer-88142

    08/06/2022, 5:59 PM
    but i want to create these reports on CI
  • f

    flaky-table-24226

    08/06/2022, 8:46 PM
    Hello, not sure if this is to place to write these kind of things (apologizes if it's already brough up) but cypress.io has a broken link on front page. The "Command Log" links to resource/page that does not exist.
  • f

    flaky-table-24226

    08/06/2022, 8:47 PM
    https://docs.cypress.io/test-runner#Command-Log
  • s

    salmon-computer-88142

    08/08/2022, 4:54 PM
    how can i run something in the browser before all the tests run
  • s

    salmon-computer-88142

    08/08/2022, 4:54 PM
    i need to click accept cookies button
  • s

    salmon-computer-88142

    08/08/2022, 5:26 PM
    how can i click on a button only if it exists?
  • b

    bitter-fountain-36713

    08/08/2022, 5:28 PM
    Use
    before()
    or
    beforeEach()
    hook in spec or support file.
  • s

    salmon-computer-88142

    08/08/2022, 6:11 PM
    before will run once?
  • s

    salmon-computer-88142

    08/08/2022, 6:12 PM
    or per spec file
  • f

    faint-spring-80499

    08/08/2022, 7:43 PM
    Here’s a short a to-the-point piece of content that I’ve just published. I hope you like it. https://dev.to/walmyrlimaesilv/a-simple-cypress-exercise-2lfe
  • b

    bitter-fountain-36713

    08/08/2022, 7:50 PM
    before()
    will run only once https://docs.cypress.io/guides/core-concepts/writing-and-organizing-tests#Hooks
  • s

    stale-optician-85950

    08/08/2022, 9:08 PM
    Why bother interacting with a cookie banner, if it's not part of your intended test journey? Have a look at the dropped cookie key/value details when you manually accept it and recreate that with setCookie() before your test begins.
  • m

    microscopic-crowd-9149

    08/09/2022, 1:31 AM
    i have installed CICD with AWS code pipeline i am using " npx cypress run --record --browser electron --key XXXXXX-XXXX-XXXXX " to record & i have projectId in cypress.config.js but system giving me error:- Your Record Key d30f4...3ce5d is not valid with this projectId: d30f4320-2281-XXXX-ad73-XXXXXXXX but sytem showing me Key as project id ( same code working fine locally )
  • m

    microscopic-crowd-9149

    08/09/2022, 2:17 AM
    Hi i have same issue with AWS code build how you resolved this issue
  • s

    swift-cricket-72233

    08/09/2022, 3:17 AM
    How do I create assertions/test/validate a pop-up from the main parent window? The pop-up could be a modal dialog, a new tab or a new window. Any best practices that you would recommend to test these scenarios?
  • r

    rich-pharmacist-74804

    08/09/2022, 7:13 AM
    Hello All! Is it possible to add data from API? My scenario: I don't have any UI screen to add data. If I have to add any data, the Backend will add the data through API and update the server. After that added data will be listed in the portal. I want to solve the above scenario by cypress e2e. I want to add the data through API. Thank you.
    c
    • 2
    • 2
  • s

    salmon-computer-88142

    08/09/2022, 9:50 AM
    because when error occurs i see that banner overlapping the ui
  • s

    salmon-computer-88142

    08/09/2022, 9:51 AM
    and i want to get rid of it
  • s

    salmon-computer-88142

    08/09/2022, 9:51 AM
    and it also manipulates the DOM so sometimes tests fail because i need to use different selector
  • s

    stale-optician-85950

    08/09/2022, 10:24 AM
    Yes of course, nobody wants a rouge banner appearing. But I meant setting the cookie banner cookie would get rid of it for you for the duration of your test.
  • s

    salmon-computer-88142

    08/09/2022, 10:49 AM
    per 'it' clause? or entire tests?
  • s

    stale-optician-85950

    08/09/2022, 10:58 AM
    You can do either. Lets say your banner is from OneTrust: 1. Put setCookie() in a before() hook and you then need to persevere the cookie: https://docs.cypress.io/api/cypress-api/cookies#Defaults which will always be preserved across tests.
    Copy code
    cy.setCookie('OptanonAlertBoxClosed', '2099-01-01T01:01:01.926Z');
    cy.visit(url);
    2. Put setCookie() in beforeEach() hook and it will be called before each it() block, so no need to preserve. Anyhow all I'm getting at is, that I avoid any UI interaction that is not explicit to my test requirement.
  • s

    swift-kitchen-62493

    08/09/2022, 12:59 PM
    Hi, is it possible to make .exe applications in visual studio code + cypress? if yes, then is there any tutorial how to make it?
  • s

    salmon-computer-88142

    08/09/2022, 8:15 PM
    does anyone collect code coverage using cypress?
  • s

    salmon-computer-88142

    08/09/2022, 8:16 PM
    as im running backend service as a docker container, the reports i get incorrect, because it is from the path inside the container, not the path on the host machine
  • s

    stale-park-86404

    08/10/2022, 6:04 AM
    Hi, I have tried using fixture and it works in my test well. However, I just recently tried importing the fixture file and directly accessing the data inside without using the cy.fixture(). So what's the difference of this compared to directly opening the json file? cy.fixture(‘user’).then((user) =>{ const username = user.username cy.get(‘selector’).type(username) } vs Import ‘/path/to/json/file’ cy.get(‘selector’).type(jsonfile.username)
1...747576...127Latest