Skip to content

Commit 1dcd822

Browse files
edwinnyawolisrawlins
authored andcommitted
Add any matcher example in README.md
The other matchers shown here are functions but `any` is not. This may cause users to assume all matchers are functions and try calling `any()`.
1 parent bc613fe commit 1dcd822

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -139,6 +139,7 @@ when(cat.walk(["roof","tree"])).thenReturn(2);
139139
140140
// ... or matchers
141141
when(cat.eatFood(argThat(startsWith("dry")))).thenReturn(false);
142+
when(cat.eatFood(any)).thenReturn(false);
142143
143144
// ... or mix aguments with matchers
144145
when(cat.eatFood(argThat(startsWith("dry")), hungry: true)).thenReturn(true);

0 commit comments

Comments
 (0)