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

[Test]: flakey test with save #5616

Merged
merged 1 commit into from
Sep 30, 2020
Merged

Conversation

snewcomer
Copy link
Contributor

@snewcomer snewcomer commented Sep 30, 2020

on master.

Screen Shot 2020-09-29 at 10 08 26 PM

Seems to be flakey b/c recent commits do not suggest this was failing in the CI runs. But pulling and running locally will fail (most of the time).

emberjs/data#7337

@@ -43,6 +43,7 @@ module('Integration | Component | user profile ics', function(hooks) {

await render(hbs`<UserProfileIcs @isManaging={{true}} @user={{this.user}} @setIsManaging={{noop}} />`);
await click('.refresh-key');
await settled();
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'm guessing our test harness awaits this chain of async operations. But we must be missing something 🤔

  @dropTask
  *refreshKey() {
    const token = yield this.randomToken(this.args.user.id);
    this.args.user.set('icsFeedKey', token);
    yield this.args.user.save();
    this.args.setIsManaging(false);
    this.hasSavedRecently = true;
    yield timeout(500);
    this.hasSavedRecently = false;
  }

Copy link
Member

Choose a reason for hiding this comment

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

IIRC I pulled this settled() out a week or so ago since it didn't seem to be needed anymore and tests ran, but I'm not fussed about it being back. Thanks!

@jrjohnson jrjohnson merged commit e321ea2 into ilios:master Sep 30, 2020
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.

2 participants