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
Fix form test flakiness #8096
Fix form test flakiness #8096
Conversation
Hi, ampproject bot here! Here are a list of the owners that can approve your files.
|
extensions/amp-form/0.1/amp-form.js
Outdated
}); | ||
}); | ||
this.xhrSubmitPromise_ = p; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's only set this in test mode, Closure can eliminate the property in prod, then.
Hi, ampproject bot here! Here are a list of the owners that can approve your files. You may leave an issue comment stating "@ampprojectbot retry!" to force me to re-evaluate this Pull Request's status /to @aghassemi
For any issues please file a bug at https://github.com/google/github-owners-bot/issues |
extensions/amp-form/0.1/amp-form.js
Outdated
@@ -366,8 +370,12 @@ export class AmpForm { | |||
/** @type {../../../src/service/xhr-impl.FetchResponse} */ ( | |||
error)); | |||
rethrowAsync('Form submission failed:', error); | |||
return error; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remove, we are not using this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
Fix the flakiness in test-amp-form.
It seems unnecessary for the test to check if the error was thrown async. It should be enough to check that the error template was rendered.
Fixes #7962