You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When i have a test that doesn't use semantic-dom-diff I expect the should assertion not to be asynchronous
Actual Behavior
An equal assertion to be synchronous
Describe what happens instead.
When using eslint it picks up the typings from chai-dom-diff-plugin.d.ts and reports async calls should be awaited.
error Promises must be awaited, end with a call to .catch, end with a call to .then with a rejection handler or be explicitly marked as ignored with the void operator.
Dependabot just opened a PR in my project updating @open-wc/testing from 3.1.8 to 3.2.0 which also updates @open-wc/semantic-dom-diff from 0.19.7 to 0.20.0 and now eslint is failing with the same error.
The code that's being flagged:
constel: CustomElement=awaitfixture(html`<custom-element><input...></custom-element>`);constinput=el.querySelector<HTMLInputElement>("input");// Promises must be awaited, end with a call to .catch, end with a call to .then with a rejection handler or be explicitly marked as ignored with the `void` operator.// @typescript-eslint/no-floating-promises - https://typescript-eslint.io/rules/no-floating-promisesexpect(input).to.equal(document.activeElement);
Expected behavior
When i have a test that doesn't use semantic-dom-diff I expect the should assertion not to be asynchronous
Actual Behavior
An equal assertion to be synchronous
Describe what happens instead.
When using eslint it picks up the typings from chai-dom-diff-plugin.d.ts and reports async calls should be awaited.
error Promises must be awaited, end with a call to .catch, end with a call to .then with a rejection handler or be explicitly marked as ignored with the void operator.
Additional context
See eslint result in the console output of this stackblitz project:
https://stackblitz.com/edit/semantic-dom-diff-typeings?file=src%2FArithmetic.test.ts
Which packages and versions are you using.
@open-wc/testing: "3.1.8",
@typescript-eslint/eslint-plugin: "^5.51.0",
@typescript-eslint/parser: "^5.51.0",
eslint: "^8.40.0",
eslint-plugin-lit: "^1.8.3",
Also see: package.json
The text was updated successfully, but these errors were encountered: