explorer_test 흔들림: Rsync 화면의 새 폴더가 골라질 때까지 기다리기

전체 시험 중 바쁠 때 새 폴더가 보인 직후 (골라지기 전) 확인해 실패했다.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
묶음4
RyuJongJin 2026-10-10 06:08:46 +09:00
parent 36e724afc1
commit d5bb200d00
1 changed files with 6 additions and 3 deletions

View File

@ -415,10 +415,13 @@ void main() {
await tester.pumpAndSettle(); await tester.pumpAndSettle();
await tester.enterText(find.byType(TextField), '새로만든'); await tester.enterText(find.byType(TextField), '새로만든');
await act(tester, () => tester.tap(find.widgetWithText(FilledButton, '확인'))); await act(tester, () => tester.tap(find.widgetWithText(FilledButton, '확인')));
await settle(tester, () => find.text('새로만든').evaluate().isNotEmpty); // 만든 폴더가 보이고 골라질 때까지 (전체 시험 중 바쁠 때는 고르기가 조금 늦다)
Finder newRow() => find.ancestor(of: find.text('새로만든'), matching: find.byType(Material)).first;
await settle(tester, () =>
find.text('새로만든').evaluate().isNotEmpty &&
find.descendant(of: newRow(), matching: find.byTooltip('고르기 취소')).evaluate().isNotEmpty);
expect(Directory(p.join(right, 'rsub', '새로만든')).existsSync(), isTrue); expect(Directory(p.join(right, 'rsub', '새로만든')).existsSync(), isTrue);
final newRow = find.ancestor(of: find.text('새로만든'), matching: find.byType(Material)).first; expect(find.descendant(of: newRow(), matching: find.byTooltip('고르기 취소')), findsOneWidget);
expect(find.descendant(of: newRow, matching: find.byTooltip('고르기 취소')), findsOneWidget);
expect(find.descendant(of: find.ancestor(of: find.text('rsub'), matching: find.byType(Material)).first, expect(find.descendant(of: find.ancestor(of: find.text('rsub'), matching: find.byType(Material)).first,
matching: find.byTooltip('고르기 취소')), findsNothing); // 창마다 하나만 matching: find.byTooltip('고르기 취소')), findsNothing); // 창마다 하나만
}); });