Skip to content

Commit 19fc17f

Browse files
committed
for test
1 parent 93b0bae commit 19fc17f

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

addons/s3compatsigv4/tests/test_view.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
import addons.s3compatsigv4.settings as s3compatsigv4_settings
2020
from website.util import api_url_for
2121
from admin.rdm_addons.utils import get_rdm_addon_option
22+
from flask import _request_ctx_stack
2223

2324
pytestmark = pytest.mark.django_db
2425

@@ -304,3 +305,6 @@ def test_create_bucket_fail(self, mock_make):
304305
ret = self.app.post_json(url, {'bucket_name': 'doesntevenmatter'}, auth=self.user.auth, expect_errors=True)
305306

306307
assert_equals(ret.body.decode(), '{"message": "This should work", "title": "Problem connecting to S3 Compatible Storage (SigV4) "}')
308+
309+
while _request_ctx_stack.top is not None and _request_ctx_stack.top is not self.context:
310+
_request_ctx_stack.pop()

0 commit comments

Comments
 (0)