test(mobile): preserve full-key mention accessibility

Signed-off-by: Logan Johnson <loganj@squareup.com>
This commit is contained in:
Logan Johnson
2026-09-05 18:01:16 -04:00
parent 4e0054ff39
commit 2ac8764b26

View File

@@ -6,6 +6,7 @@ void main() {
testWidgets('namesake chips resolve exact tagged keys, not tag order', (
tester,
) async {
final semantics = tester.ensureSemantics();
final first = 'a' * 64;
final second = 'b' * 64;
String? tapped;
@@ -23,6 +24,8 @@ void main() {
expect(tapped, first);
await tester.tap(find.text('Scout (bbbbbbbb…bbbb)'));
expect(tapped, second);
expect(find.bySemanticsLabel(RegExp('Scout.*$second')), findsOneWidget);
expect(tester.takeException(), isNull);
semantics.dispose();
});
}