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
|[await-async-query](docs/rules/await-async-query.md)| Enforce promises from async queries to be handled |![dom-badge][]![angular-badge][]![react-badge][]![vue-badge][]||
131
131
|[await-async-utils](docs/rules/await-async-utils.md)| Enforce async utils to be awaited properly |![dom-badge][]![angular-badge][]![react-badge][]![vue-badge][]||
132
-
|[await-fire-event](docs/rules/await-fire-event.md)| Enforce async fire event methods to be awaited |![vue-badge][]||
132
+
|[await-fire-event](docs/rules/await-fire-event.md)| Enforce promises from fire event methods to be handled|![vue-badge][]||
133
133
|[consistent-data-testid](docs/rules/consistent-data-testid.md)| Ensure `data-testid` values match a provided regex. |||
134
134
|[no-await-sync-events](docs/rules/no-await-sync-events.md)| Disallow unnecessary `await` for sync events |||
135
135
|[no-await-sync-query](docs/rules/no-await-sync-query.md)| Disallow unnecessary `await` for sync queries |![dom-badge][]![angular-badge][]![react-badge][]![vue-badge][]||
awaittriggerEvent(); // ...and handling promise from it is correct also
51
+
52
+
// using `Promise.all` or `Promise.allSettled` with an array of promises is valid
53
+
awaitPromise.all([
54
+
fireEvent.focus(getByLabelText('username')),
55
+
fireEvent.blur(getByLabelText('username')),
56
+
]);
37
57
```
38
58
39
59
## When Not To Use It
40
60
41
-
`fireEvent` methods are only async in Vue Testing Library so if you are using another Testing Library module, you shouldn't use this rule.
61
+
`fireEvent` methods are not async on all Testing Library packages. If you are not using Testing Library package with async fire event, you shouldn't use this rule.
@@ -260,52 +324,24 @@ export function detectTestingLibraryUtils<
260
324
};
261
325
/**
262
326
* Takes a MemberExpression or an Identifier and verifies if its name comes from the import in TL
263
-
* @param node a MemberExpression (in "foo.property" it would be property) or an Identifier (it should be provided from a CallExpression, for example "foo()")
327
+
* @param node a MemberExpression (in "foo.property" it would be property) or an Identifier
0 commit comments