The smoke testing is broken for any route containing a placeholder
stof opened this issue · comments
The trait testing all routes is sending a request to $route->getPath()
. this is flawed as $route->getPath()
is not the URL corresponding to that route (the only case where it is the URL is for static routes).
If you intentionally support only static routes for now, I suggest making that explicit:
- rename
SmokeTestAllRoutes
toSmokeTestStaticRoutes
- filter the data provider to only provide the static routes
Your proposal is the best one, since I don't think there is a proper way to test non-static routes without a clear view on what can be injected.
I will make the changes 👍
Fixed in latest commits, will publish a new tag and update documentation later 👍
With the latest update, any route for which all dynamic parameters have a default
will also be tested, since they can be considered as static too.
Let's close for now, feel free to reopen if anything goes wrong on this particular subject!