Skip to content
This repository has been archived by the owner on Jun 21, 2022. It is now read-only.

Tests fail with CATALYST_DEBUG=1 #141

Open
dboehmer opened this issue Jan 7, 2021 · 0 comments
Open

Tests fail with CATALYST_DEBUG=1 #141

dboehmer opened this issue Jan 7, 2021 · 0 comments

Comments

@dboehmer
Copy link
Owner

dboehmer commented Jan 7, 2021

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.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant