Skip to content

Some integration tests are flaky WRT "loader background" #4653

Open
@cwillisf

Description

@cwillisf

Expected Behavior

Integration test results should only depend on the code: re-running a failed test without any code changes should never lead to success.

Actual Behavior

Occasionally, some of the integration tests fail with an error like this:

 FAIL  test/integration/blocks.test.js (57.199s)
  ● Working with the blocks › Blocks report when clicked in the toolbox
    WebDriverError: unknown error: Element <span>...</span> is not clickable at point (59, 74). Other element would receive the click: <div class="loader_background_2DPrW">...</div>

I have personally seen this issue with blocks.test.js and backpack.test.js but I suspect it's possible with other tests as well. These tests seem to fail for me locally more often than on Travis CI, but I have seen both.

Example: https://travis-ci.org/LLK/scratch-gui/builds/506044876#L2046

I believe this is a timing issue related to the loading / project creation screen sometimes being in the way of the test's simulated click.

Steps to Reproduce

  1. Build with npm run build
  2. Run integration tests with npm run test:integration

Alternatively:

  1. Build with npm run build
  2. Run an individual integration test with `./node_modules/.bin/jest test/integration/backpack.test.js'

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions