Skip to content

Commit

Permalink
emoji [nfc]: Make testCandidate visible for testing
Browse files Browse the repository at this point in the history
We'll need this as we add more logic here.
  • Loading branch information
gnprice committed Dec 8, 2024
1 parent 0e137db commit 2177758
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions lib/model/emoji.dart
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,7 @@ class EmojiAutocompleteView extends AutocompleteView<EmojiAutocompleteQuery, Emo
}

static EmojiAutocompleteResult? _testCandidate(EmojiAutocompleteQuery query, EmojiCandidate candidate) {
return query._testCandidate(candidate);
return query.testCandidate(candidate);
}
}

Expand Down Expand Up @@ -336,7 +336,8 @@ class EmojiAutocompleteQuery extends ComposeAutocompleteQuery {
return EmojiAutocompleteView.init(store: store, query: this);
}

EmojiAutocompleteResult? _testCandidate(EmojiCandidate candidate) {
@visibleForTesting
EmojiAutocompleteResult? testCandidate(EmojiCandidate candidate) {
return matches(candidate) ? EmojiAutocompleteResult(candidate) : null;
}

Expand Down

0 comments on commit 2177758

Please sign in to comment.