Plans test fails (switching accounts doesn't seem to work)
With a fresh install of JSP and my Stripe connected in development, I ran bin/rake to find one test failing:
Failure:
Failure:
Jumpstart::PlansTest#test_can_view_subscribe_page_for_a_account_plan [/Users/morgler/code/setlists/test/integration/plans_test.rb:55]:
Expected false to be truthy.
It's only the line that tests whether the account name is shown on the checkout form (everything else works if I comment out that assert). I checked the credentials for test and was surprised to find existing test keys there – is that correct? I tried bin/rake with these stock keys and also with my own keys (from the Stripe test environment), but neither made the test pass.
Am I missing something?
I had the same test failing on a new install of JSP. I doubt it has anything to do with Stripe though. First investigation showed that the switch_account test helper doesn't seem to actually switch the account (the name on the account page is still that of the personal account)! My app is using personal and team accounts and lets them be switched via subdomains (I turned off subdomain switching, but it made no difference).
(BTW: That test first failed with an UnsafeRedirect error with subdomain switching turned on, so I had to add "allow_other_host: true" to the subdomain redirect in the AccountsController. Now it works in development, but it causes the above mentioned test to fail, because the switching doesn't work during tests.)
(BTW: That test first failed with an UnsafeRedirect error with subdomain switching turned on, so I had to add "allow_other_host: true" to the subdomain redirect in the AccountsController. Now it works in development, but it causes the above mentioned test to fail, because the switching doesn't work during tests.)
Notifications
You’re not receiving notifications from this thread.