Skip to content
This repository has been archived by the owner on Oct 22, 2024. It is now read-only.

Add more advice away from predicate #233

Merged
merged 5 commits into from
Nov 21, 2023
Merged

Conversation

natebosch
Copy link
Contributor

Add a best practice entry and expand the dartdoc for predicate to
mention that the failure messages are not as detailed as TypeMatcher,
and that the latter is preferred when the value can fail in more than
one way.

Add a generic argument to the example usage - most cases should prefer
to include a generic.

Cleanup an unnecessary private typedef with a single usage.

Add a best practice entry and expand the dartdoc for `predicate` to
mention that the failure messages are not as detailed as `TypeMatcher`,
and that the latter is preferred when the value can fail in more than
one way.

Add a generic argument to the example usage - most cases should prefer
to include a generic.

Cleanup an unnecessary private `typedef` with a single usage.
@natebosch natebosch requested a review from jakemac53 November 2, 2023 23:42
lib/src/core_matchers.dart Outdated Show resolved Hide resolved
@natebosch natebosch merged commit fcbd361 into master Nov 21, 2023
4 checks passed
@natebosch natebosch deleted the type-matcher-over-predicate branch November 21, 2023 21:51
mosuem pushed a commit to dart-lang/test that referenced this pull request Oct 17, 2024
Add a best practice entry and expand the dartdoc for `predicate` to
mention that the failure messages are not as detailed as `TypeMatcher`,
and that the latter is preferred when the value can fail in more than
one way.

Add a generic argument to the example usage - most cases should prefer
to include a generic.

Cleanup an unnecessary private `typedef` with a single usage.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants