Skip to content

Commit

Permalink
Fix 2 failing tests by forwarding PatrolFinder.describeMatch()
Browse files Browse the repository at this point in the history
  • Loading branch information
bartekpacia committed Nov 13, 2023
1 parent c5db170 commit 6e07363
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions packages/patrol_finders/lib/src/custom_finders/patrol_finder.dart
Original file line number Diff line number Diff line change
Expand Up @@ -444,6 +444,9 @@ class PatrolFinder extends MatchFinder {
/// Returns true if this finder finds at least 1 widget.
bool get exists => evaluate().isNotEmpty;

@override
String describeMatch(Plurality plurality) => finder.describeMatch(plurality);

/// Returns true if this finder finds at least 1 visible widget.
bool get visible {
final isVisible = hitTestable().evaluate().isNotEmpty;
Expand All @@ -460,6 +463,9 @@ class PatrolFinder extends MatchFinder {
@override
FinderResult<Element> evaluate() => finder.evaluate();

@override
bool tryEvaluate() => finder.tryEvaluate();

@override
Iterable<Element> apply(Iterable<Element> candidates) {
return finder.apply(candidates);
Expand Down Expand Up @@ -497,6 +503,12 @@ class PatrolFinder extends MatchFinder {
@override
bool precache() => finder.precache();

@override
FinderResult<Element> get found => finder.found;




@override
PatrolFinder hitTestable({Alignment at = Alignment.center}) {
return PatrolFinder(finder: finder.hitTestable(at: at), tester: tester);
Expand Down

0 comments on commit 6e07363

Please sign in to comment.