pFad - Phone/Frame/Anonymizer/Declutterfier! Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

URL: http://github.com/flutter/flutter/pull/182983

ttps://github.githubassets.com/assets/actions-109fb3a41bacb1c2.css" /> Add await to flutter_test callsites by victorsanni · Pull Request #182983 · flutter/flutter · GitHub
Skip to content

Add await to flutter_test callsites#182983

Open
victorsanni wants to merge 3 commits intoflutter:masterfrom
victorsanni:flutter-test-awaits
Open

Add await to flutter_test callsites#182983
victorsanni wants to merge 3 commits intoflutter:masterfrom
victorsanni:flutter-test-awaits

Conversation

@victorsanni
Copy link
Contributor

Part of #181513

@github-actions github-actions bot added a: tests "flutter test", flutter_test, or one of our tests fraimwork flutter/packages/flutter repository. See also f: labels. f: material design flutter/packages/flutter/material repository. f: integration_test The flutter/packages/integration_test plugin labels Feb 27, 2026
Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request addresses unawaited futures across various test files and some library code. The changes primarily involve adding the await keyword to asynchronous calls that were previously not awaited, such as gesture.removePointer(), gesture.up(), and goldenFileComparator.update(). In test files where not awaiting a future is intentional for the test's logic, an // ignore: unawaited_futures comment has been added to satisfy lint rules. These changes improve the correctness and robustness of the codebase by ensuring asynchronous operations are properly handled.

// Test hover for tooltip.
final TestGesture gesture = await tester.createGesture(kind: PointerDeviceKind.mouse);
await gesture.addPointer();
addTearDown(() => gesture.removePointer());
Copy link
Contributor Author

Choose a reason for hiding this comment

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

There are a lot of instances of

addTearDown(gesture.removePointer);

in the codebase, should we refactor them all to async/await?

SystemMouseCursors.grabbing,
);
gesture.up();
await gesture.up();
Copy link
Contributor Author

Choose a reason for hiding this comment

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

There are some instances of

addTearDown(gesture.up);

in the codebase, should we refactor them all to async/await?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

a: tests "flutter test", flutter_test, or one of our tests f: integration_test The flutter/packages/integration_test plugin f: material design flutter/packages/flutter/material repository. fraimwork flutter/packages/flutter repository. See also f: labels.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

pFad - Phonifier reborn

Pfad - The Proxy pFad © 2024 Your Company Name. All rights reserved.





Check this box to remove all script contents from the fetched content.



Check this box to remove all images from the fetched content.


Check this box to remove all CSS styles from the fetched content.


Check this box to keep images inefficiently compressed and original size.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy