Addepar / Addepar/ember-table

Integration tests do not always wait for table to render

Open
#1,120 0 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
1.7k
Forks
351
Avg merge
1d 22h
Merged PRs (30d)
1

Description

We are on Ember Table V5.0.6. We used the setupEmberTableForTest(); helper in our tests.
But our integration test are still flaky. It seems that some rendering tasks that are not completed before the tests moves on to the next line despite the await call.

I looked at Ember table's tests and I noticed that settled() is called after render() is called.

This fixed my failing tests but this triggers the no-settled-after-test-helper eslint error.

What can be done to fix this without having to call settled() after render() is called?

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with setupEmberTableForTest and tests/helpers/generate-table.js around line 162, where render() and settled() are used. Reproduce the flaky integration-test behavior and determine how the helper can wait for rendering without requiring a separate settled() call; done means the tests are reliable and pass no-settled-after-test-helper linting.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
frontend, testing
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.