Uploaded image for project: 'Metron (Retired)'
  1. Metron (Retired)
  2. METRON-1971

Short timeout value in Cypress may cause build failures

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Done
    • Major
    • Resolution: Done
    • None
    • 0.7.1
    • None

    Description

      According to the Cypress docs, it is unnecessary to add a wait command after cy.visit. "Waiting for this is unnecessary because the cy.visit() resolves once the page fires its load event. By that time all of your assets have been loaded including javascript, stylesheets, and html."

      However, the problem is with an Angular application, the page firing a load event does not mean that the entire view has rendered yet. In systems where memory is scarce, such as a Travis environment or a machine that has memory-intensive applications running, this means a page load can take a few seconds (or possibly even longer).

      We currently use the default timeout in Cypress, which is only 4000ms. I believe this short timeout can cause failures like this in Metron: https://travis-ci.org/apache/metron/jobs/483945575

      We should increase the defaultCommandTimeout in cypress.json to something like 30000ms or greater to prevent failures like this in the future.

      Attachments

        Issue Links

          Activity

            People

              sardell Shane Ardell
              sardell Shane Ardell
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 2h 50m
                  2h 50m