Tests fail with CATALYST_DEBUG=1
Created by: dboehmer
That's what happens when you introduce code branches into your app depending on CATALYST_DEBUG …
In debug mode HTTP does not redirect to HTTPS in order to allow development on localhost without a valid HTTPS certificate. This breaks some tests. CATALYST_DEBUG=1
is useful to run a test with verbose debug output from Catalyst, e.g. POST data and involved Catalyst actions.
- For some tests like Is the current URL /settings? this could be fixed
- For other tests like testing the HTTPS redirect there could be no fix.
Do we just ignore this? How could we fix that? Maybe extend $t->base_is()
to rewrite the URL scheme or change every call to $t->base_like( qr{https?://...} )
.
For tests that can't be fixed with CATALYST_DEBUG
we could skip them.
Edited by Daniel Böhmer