Not able to match @null@||@array@
maciej-sz opened this issue · 1 comments
maciej-sz commented
The case is that I am matching optional array, which can be NULL.
A little modified example form php-matcher.norbert.tech
(link):
{
"users": [
{
"firstName": "@string@",
"lastName": "@string@",
"title": "@string@",
"created": "@string@.isDateTime()",
"roles": "@null@||@array@"
}
]
}
and the output contains:
#162 Matcher Coduo\PHPMatcher\Matcher\ScalarMatcher error: "Array(2)" does not match "@array@".
norberttech commented
This one was fixed by @mtomala and released:
https://github.com/coduo/php-matcher/releases/tag/5.0.1
https://github.com/coduo/php-matcher/releases/tag/4.0.2
Thanks again @mtomala !