Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add an overload of map that allows you to fail the conversion by returning nil. #1177

Merged
merged 3 commits into from
Dec 12, 2024

Conversation

younata
Copy link
Member

@younata younata commented Dec 11, 2024

This corrects the documentation for Map (which listed the old name of the matcher), and it also adds a version of map that works well with type coercion (i.e. the as? operator).

Checklist - While not every PR needs it, new features should consider this list:

  • Does this have tests?
  • Does this have documentation?
  • Does this break the public API (Requires major version bump)?
  • Is this a new feature (Requires minor version bump)?

@younata younata merged commit 74185db into main Dec 12, 2024
6 of 16 checks passed
@younata younata deleted the failable_map_matcher branch December 12, 2024 00:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant