made the return url in the tests more complete, and pass through get params to subscription confirm
This commit is contained in:
parent
f993311e7c
commit
977ce8ca8b
|
@ -18,6 +18,7 @@ pipeline:
|
|||
- python manage.py test mhackspace --verbosity 2
|
||||
|
||||
publish-test:
|
||||
pull: True
|
||||
image: appleboy/drone-ssh
|
||||
host: maidstone-hackspace.org.uk
|
||||
user: ${SSH_USERNAME}
|
||||
|
@ -27,6 +28,7 @@ pipeline:
|
|||
- echo 'to be added'
|
||||
|
||||
publish-live:
|
||||
pull: True
|
||||
image: appleboy/drone-ssh
|
||||
user: ${SSH_USERNAME}
|
||||
key: ${SSH_KEY}
|
||||
|
|
|
@ -37,8 +37,12 @@ class TestSubscriptionSuccessRedirectView(BaseUserTestCase):
|
|||
}
|
||||
|
||||
request = self.factory.post(
|
||||
reverse('join_hackspace_success', kwargs={'provider': 'gocardless'}),
|
||||
{'signature': 'test_signature'}
|
||||
reverse('join_hackspace_success', kwargs={'provider': 'gocardless'}), {
|
||||
'resource_id': 'R01',
|
||||
'resource_type': 'subscription',
|
||||
'resource_url': 'https://sandbox.gocardless.com',
|
||||
'signature': 'test_signature'
|
||||
}
|
||||
)
|
||||
|
||||
setattr(request, 'session', 'session')
|
||||
|
|
|
@ -82,7 +82,7 @@ class MembershipJoinSuccessView(LoginRequiredMixin, RedirectView):
|
|||
payment_provider = 'gocardless'
|
||||
provider = select_provider(payment_provider)
|
||||
result = provider.confirm_subscription(
|
||||
provider_response=kwargs
|
||||
provider_response=self.request.GET
|
||||
)
|
||||
|
||||
#if something went wrong return to profile with an error
|
||||
|
|
Loading…
Reference in New Issue