You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
HTTP mock: parse query and form parameters the way Symfony encodes them #106
Part of #100. Line numbers refer to branch chore/php-8.4-dependabot (#98). Verified = reproduced, suspected = from reading the code.
Several query and form values are parsed differently from what Symfony actually sends. Fixing this changes which mocks match, so it is planned for 8.0.
explode('=') has no limit, so ?t=YQ== is parsed as YQ and base64 cursors never match (RealRequestFactory.php:157). Verified.
Symfony's query option encodes arrays as ids[0]=1&ids[1]=2 and filter[a]=1. These are parsed into flat keys, so none of these ever match: queryParam('ids[]', …), queryParam('ids', [...]), queryParam('filter', [...]) (RealRequestFactory.php:147-178). Verified.
queryParam('ids[]', ['1', '2']) doesn't match even ?ids[]=1&ids[]=2 (Matcher/QueryParamMatcher.php:58). Verified.
Form bodies have the same problems: t=YQ== is truncated, and array fields become tags[0], so requestParam('tags[]', …) never matches (RealRequestFactory.php:83-88). Verified.
Breaking: mocks written against the current parsing, e.g. queryParam('t', 'YQ'), stop matching.
Activity