in reply to Re: Mocking isa under Test::Deep
in thread Mocking isa under Test::Deep
The authors of a test tool have unilaterally decided that you [...] are [not] allowed to use a comparator function that they didn't provide,
A more accurate summary would be that a test tool uses a special class as a sentinel and complains if a sentinel value turns up in a place where it has no business being. Meanwhile, a sloppy hack to get around draconian type checking had the side effect of making a non-sentinel appear to be a sentinel. The solution was to make the hack slightly less sloppy.
I would put more blame on the type checking that requires the hack than on the use of an internal class name as a way to create and detect sentinels.
- tye
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Mocking isa under Test::Deep (sentinel)
by BrowserUk (Patriarch) on May 03, 2016 at 04:26 UTC | |
by tye (Sage) on May 03, 2016 at 17:26 UTC |