Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

remove test waiter #5544

Merged
merged 5 commits into from
Jul 26, 2018
Merged

remove test waiter #5544

merged 5 commits into from
Jul 26, 2018

Conversation

runspired
Copy link
Contributor

The test waiter is prone to pwn-ing folks with the current implementation. New implementation to follow.

if (DEBUG) {
this.__asyncRequestCount = 0;

Ember.Test.registerWaiter(() => {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This requires a sibling Ember.Test.unregisterWaiter(fn) or it will leak

return ASYNC_REQUEST_COUNT === 0;
});
}

export function guardDestroyedStore(promise, store, label) {
let wrapperPromise = resolve(promise, label).then(v => promise);

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we put the incrementer here? If so, that would likely bit-rot related tester waiter imbalances.

@runspired runspired merged commit a5f1d41 into master Jul 26, 2018
@runspired runspired deleted the revert-async branch July 26, 2018 23:59
bmac pushed a commit that referenced this pull request Jul 31, 2018
* remove test waiter

* Add store encapsulated waiter

* dont leak waiters

* if debug add bugs

* make calls symetrical

(cherry picked from commit a5f1d41)
NullVoxPopuli pushed a commit to NullVoxPopuli/data that referenced this pull request Sep 8, 2018
* remove test waiter

* Add store encapsulated waiter

* dont leak waiters

* if debug add bugs

* make calls symetrical
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants