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

    best-agency-72362

    10/21/2022, 10:50 PM
    hello, i have this error when i do npm run test : libva error: vaGetDriverNameByIndex() failed with unknown libva error, driver_name = (null) [4654:1021/182522.158673:ERROR:gpu_memory_buffer_support_x11.cc(44)] dri3 extension not supported.
  • h

    hundreds-author-68171

    10/21/2022, 10:52 PM
    Hello! I recently setup github actions with cypress to run on a scheduled time. github config file below:
    Copy code
    name: scheduled-cypress-main
    on:
      schedule:
        # runs tests every midnight
        - cron: '0 0 * * *'
    jobs:
      cypress-run:
        runs-on: macos-11
        steps:
          - name: Checkout
            uses: actions/checkout@v2
          - name: Cypress tests
            uses: cypress-io/github-action@v4
            with:
              install-command: npm ci
              command: npm run cy --record --key ${{ secrets.CY_ACCESS_KEY }}
    This runs however I do not see recorded results on cypress.io dashboard. Is there an extra configuration I would need to set?
  • g

    green-boots-72737

    10/22/2022, 1:46 PM
    Hi all, quick question, I can't find it in the docs. Is there a way to use cypress outside of a spec file? ie. Can I just use it as part of a normal program? Something like
    import 'cy' from 'cypress'
    then
    cy.visit('http://mysite.com')
  • g

    gray-kilobyte-89541

    10/22/2022, 4:46 PM
    not really, it is meant to run your tests for you, not used as a library
  • b

    brief-kite-35331

    10/22/2022, 11:56 PM
    hey, I am trying to run npm install on my new laptop for the project that is already working. But when I do that it just says Installing Cypress 10.10.0 and then just hangs there with no progress at all (not even after 20 mins) and I cannot make it to install cypress 10. I am on Windows 10 machine. Can someone help how to troubleshoot this? Thanks!
  • m

    mysterious-belgium-25713

    10/23/2022, 9:44 AM
    Are you using node lts or latest. I think I remember having a problem once with latest node and had to rollback to an older version.
  • f

    freezing-oxygen-59684

    10/23/2022, 9:59 AM
    Hi guys, i have an issue when my vpn is turned on. Im getting error - 403 forbidden. Photo attached. Without vpn at my workplace network it works when I run cypress tests!! I can reach this website while using vpn via google chrome browser, but when I run cypress test it throws this error. Any advices?
  • b

    brief-kite-35331

    10/23/2022, 10:11 AM
    I am using 16.18.0 LTS version
  • m

    mysterious-belgium-25713

    10/23/2022, 10:17 AM
    If you have a company vpn, then you need to set the proxy settings of the vpn also to your cypress.
  • m

    mysterious-belgium-25713

    10/23/2022, 10:23 AM
    Are you on a company laptop? If so maybe some settings need to be set to download cypress. Like proxies. If not I would just download the cypress binary to a folder on your machine and then set CYPRESS_INSTALL_BINARY to that file. And then try to install cypress again. This is not the correct way but can bypass installs
  • b

    brief-kite-35331

    10/23/2022, 11:23 AM
    I was able to download once I connected to vpn, so I guess it was something with firewall settings. It is my company laptop. Thanks @mysterious-belgium-25713 for reaching out
  • b

    best-agency-72362

    10/23/2022, 12:44 PM
    Can someone answer my question pls?
  • l

    lemon-animal-16490

    10/23/2022, 12:51 PM
    what do I need to test for nav link item component testing?
  • h

    hundreds-author-68171

    10/23/2022, 5:06 PM
    repinging for help, thanks in advance https://discord.com/channels/755913899261296641/763105090679865354/1033150828544020490
  • t

    thankful-pencil-94627

    10/23/2022, 10:17 PM
    I use something like this
    Copy code
    name: Cypress test github action
    on:
      schedule:
      - cron:  '0 0 1 * *'
    jobs:
      cypress-run:
        name: Cypress run
        runs-on: ubuntu-20.04
        steps:
          - name: Checkout
            uses: actions/checkout@v2
    
          - name: Set up Node.js
            uses: actions/setup-node@v1
            with:
              node-version: 14.17.0
    
          - name: Cypress run
            uses: cypress-io/github-action@v4
            with:
              record: true
              browser: chrome
            env:
              # pass the Dashboard record key as an environment variable
              CYPRESS_RECORD_KEY: {YOUR CYPRESS RECORD ID}
              CYPRESS_PROJECT_ID: {YOUR CYPRESS PROJECT ID}
  • o

    orange-book-46212

    10/24/2022, 2:16 AM
    Hi, guys, I have a problem with using badeball/cypress-cucumber-preprocessor with multiple-cucumber-html-reporter. The doc says the failed-step-screenshots will be automatically added in the JSON report, but I cannot see in the json file and html file generated after, I'm using the following config:
  • a

    acceptable-hamburger-48790

    10/24/2022, 4:10 AM
    Can you try this plugin https://github.com/dane-harnett/cypress-cucumber-attach-screenshots-to-failed-steps
  • o

    orange-book-46212

    10/24/2022, 4:21 AM
    yes, I'm using this plugin, and it's not working, I upgraded cypress to 10.10.0 and cypress-cucumber-preprocessor to the latest version
  • a

    acceptable-hamburger-48790

    10/24/2022, 4:22 AM
    Do you have a repo where you reproduce this and share it with us
  • o

    orange-book-46212

    10/24/2022, 4:24 AM
    I'm currently working on my company's project, I'll create a example repo to show this, thanks for the message
  • f

    future-eye-56254

    10/24/2022, 5:30 AM
    Hi Guys How do you compare two json objects to verify precision values ? I have 2 jsons with exact values except some with precison differences. Ex: expectedKey: 0.1100 actualKey:0.11 I want this difference to be flagged and reported. I am trying this data = expected.json cy.readFile('actual.json').should('deep.equal',data)
  • f

    future-eye-56254

    10/24/2022, 5:31 AM
    But the assertion passes without any issues
  • s

    stale-optician-85950

    10/24/2022, 7:19 AM
    That's a graphics driver error, not a Cypress error. You might need to update the graphics card driver to latest version, but this is not the space for that discussion
  • f

    freezing-piano-2792

    10/24/2022, 8:37 AM
    The plugin
    cypress-cucumber-attach-screenshots-to-failed-steps
    is entirely irrelevant when using
    @badeball/cypress-cucumber-preprocessor
  • a

    acceptable-hamburger-48790

    10/24/2022, 11:45 AM
    In that case the screenshot attach is entirely dependent on this flag screenshotOnRunFailure , is it ?
  • s

    stale-optician-85950

    10/24/2022, 11:56 AM
    Does anyone have a trick for exiting full-screen mode in a Highchart? Here is an example test block to reproduce, noting that my
    cy.realPress('{esc}')
    doesn't work:
    Copy code
    it.only('Highcharts full screen', () => {
        cy.visit('https://www.highcharts.com/demo/line-basic');
        cy.get('[title="Chart context menu"]').realClick();
        cy.get('[class="highcharts-menu-item"]').contains('View in full screen').realClick();
        // Exit full screen
        cy.realPress('{esc}');
      });
    I have also tried things like
    cy.wait(2000).get('body').realPress('{esc}');
    and
    cy.wait(2000).get('body').focus().type('{esc}');
    to accommodate the screen changing size time and ensuring html
    body
    is focused.
  • f

    freezing-oxygen-59684

    10/24/2022, 12:14 PM
    Hi guys, need another advice. We using through a host file different ip’s but the same dns. My problem is that when tests are running it links to the prod env, though my local host file is changed that it should link to test env. I’ve tried to add host parameter in config file but it doesnt worked. Example
  • g

    gray-kilobyte-89541

    10/24/2022, 1:06 PM
    interesting, seems only the menu is working to exit the fullscreen
  • s

    stale-optician-85950

    10/24/2022, 1:10 PM
    Yes, and I really only want to close it to avoid the full screen remaining open for the next tests, as I guess the Cypress logs are not visible in screenshots then. So I'm not testing that functionality, I only want to return to the default browser run state.
  • g

    gray-kilobyte-89541

    10/24/2022, 1:14 PM
    Ha, ok I just solved it, it will make a nice lesson for my plugins course and example for https://github.com/bahmutov/cypress-cdp But in general, this worked before I got the escape working
    Copy code
    cy.get('[title="Chart context menu"]').click()
      cy.get('[class="highcharts-menu-item"]')
        .contains('Exit from full screen')
        .click()
1...185186187...252Latest