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

    gray-kilobyte-89541

    04/22/2022, 5:06 PM
    I would also start writing some e2e tests using keyboard navigation only https://glebbahmutov.com/blog/test-app-using-the-keyboard/
  • g

    great-london-82425

    04/22/2022, 7:59 PM
    A great idea. I haven't used cypress-real-events yet either. Thank you, Gleb!
  • g

    glamorous-architect-52545

    04/22/2022, 8:32 PM
    did not solve ;/
  • g

    glamorous-architect-52545

    04/22/2022, 8:34 PM
    other link that i saw: https://chowdera.com/2021/03/20210327144715585p.html
  • g

    glamorous-architect-52545

    04/22/2022, 8:34 PM
    but no success too
  • c

    colossal-table-17032

    04/26/2022, 11:01 PM
    Hi there! Were you able to get this resolved? I'm trying to do something similar in my team with GH Actions + CodeBuild
  • a

    ambitious-australia-44913

    04/27/2022, 9:07 PM
    Hello, I try to open Salesforce page with Lightning Web Security (https://developer.salesforce.com/docs/component-library/documentation/en/lwc/lwc.security_lwsec_intro). But under Cypress Salesforce returns Component Error (see screenshot cypress.png). If I use Playwright, then Salesforce not returns this error (see screenshot playwright.png). Has anyone encountered anything like this? I have a reproducible example.
  • a

    acceptable-solstice-90676

    04/27/2022, 9:55 PM
    > Hey guys, how can I pass an integer on cypress? I am trying to do a Request but it is failing because the value in the body is turned into a string
  • a

    acceptable-solstice-90676

    04/27/2022, 10:00 PM
    oh I figured it out
  • s

    strong-fountain-30659

    04/28/2022, 8:55 AM
    Is there any way to get the timestamp a test started?
    Copy code
    const now = new Date(); // instead of this I would like to have something like `Cypress.currentTest.startedAt`
    cy.registerUser(email, password);
    
    cy.checkThatSomethingHappenedAfterRegisteringANewAccount(now);
  • g

    gray-kilobyte-89541

    04/28/2022, 10:44 AM
    not really, since the commands are queued up, but here is something relevant https://glebbahmutov.com/blog/cypress-timestamps/
  • s

    strong-fountain-30659

    04/28/2022, 11:09 AM
    I need to know when the test started… (not sure how that relates to commands being queued) - I guess it is the same value as reported here?
    Copy code
    interface AttemptResult {
      // ...
      startedAt: dateTimeISO
      //...  
    }
    My use case a little more explained: After I register a new User - I want to check if an event has been published in the background => to do that I can call an API that accepts a "since" parameter, here I want to pass the timestamp when the test (so, my
    it
    -block) was started so the request is as fast as possible so having Cypress.currentTest.startedAt would be great 😉
  • g

    gray-kilobyte-89541

    04/28/2022, 11:41 AM
    just take the timestamp right before the user registration, I would probably use
    beforeEach
    hook to take the timestamp of when the test is about to start
  • s

    strong-fountain-30659

    04/29/2022, 7:27 AM
    Did it like you suggested. I still would love to have it as a feature that comes from cypress, as
    Cypress.currentTest.startedAt
    or where ever you think it is more appropriate). Would save 2-4 Lines of Code in the Spec-Files when writing Tests.
  • g

    gray-kilobyte-89541

    04/29/2022, 10:35 AM
    you can always open a pull request to implement this
  • f

    fancy-lawyer-44060

    04/29/2022, 9:06 PM
    👋 Is there a way to set a cookie globally? meaning a cookie that is set by default in all tests?
  • a

    acceptable-solstice-90676

    04/30/2022, 4:52 PM
    Hi all! I am wondering why my tests fail when I record them in cypress dashboard but they don't fail when I run them headless or through the test runner?
  • d

    dazzling-angle-28206

    04/30/2022, 5:10 PM
    It might be helpful if you are a bit more expllicit about what test are failing and how. I'm pretty sure there could be several reasons for that. Nobody likes guessing games ;-)
  • a

    acceptable-solstice-90676

    04/30/2022, 6:34 PM
    Hey, I appreciate that you are trying to help, but if you don’t like guessing, don’t reply. Fifteen tests are failing for multiple reasons; I don’t want you to debug my issue, just a general answer if someone had had the same experience and its source.
  • d

    dazzling-angle-28206

    04/30/2022, 8:07 PM
    Fine, have it your way. Good luck finding someone who likes guessing games, you'll need it ;-)
  • p

    proud-napkin-47266

    05/01/2022, 12:33 AM
    lol
  • b

    bitter-fountain-36713

    05/01/2022, 1:20 AM
    Did you change anything from the last pass run?
  • r

    rough-forest-98201

    05/01/2022, 5:04 AM
    Hi guys, any way to access this class? i am try to create e2e for old game sudoku, but this game don't have any request for validate. if i type "window.Object(game)" in console will show class Sudoku. possible to access this class use cypress? if i am try console.log on my test script ["window.Object(game)"] result undefine repo => https://fredysiswanto.github.io/testing-old-game-with-cypress/sudoku/ thank you
  • p

    proud-napkin-47266

    05/01/2022, 6:04 PM
    https://docs.cypress.io/api/commands/window
  • w

    wonderful-author-91008

    05/01/2022, 9:02 PM
    Hi Guys, I noticed with cypress, it identify the element correctly in grid, but it click on wrong element, it console the correct element in output, when it click, it clicks on next element in Grid. Does anyone else faced this? I added cy.wait(1000), it started working fine, but I want to exclude wait. Does anyone face this issue please? Thank you
  • b

    bland-oil-91894

    05/02/2022, 8:22 AM
    Hi, Yes we did. The problem ended up being that the repo's meta-data was not being correctly obtained.
  • g

    gray-kilobyte-89541

    05/02/2022, 12:37 PM
    @lemon-toothbrush-55306 check my solution to you question in this blog post https://glebbahmutov.com/blog/login-words/
  • l

    lemon-toothbrush-55306

    05/02/2022, 12:58 PM
    Thanks
  • f

    flaky-fall-49668

    05/03/2022, 1:18 PM
    Hi all, I need some help, I'm trying to install some cypress plugins, but I'm running into problems. The cypress directory is located outside client app (within an /e2e. But there's a run script that defines the frontend and backend directories. I'm trying to install
    cypress-image-snapshot
    , however, i'm getting this error shown in the screenshot. I've also included the package.json screenshot too.
  • m

    magnificent-finland-58048

    05/03/2022, 3:53 PM
    how do you install any npm package? Try dotenv for instance
1...383940...192Latest