summaryrefslogtreecommitdiff
path: root/tests/settings_tests
diff options
context:
space:
mode:
authorMariusz Felisiak <felisiak.mariusz@gmail.com>2020-12-31 13:18:57 +0100
committerGitHub <noreply@github.com>2020-12-31 13:18:57 +0100
commite13b71403bd1568abed237858127677144d43d23 (patch)
tree95d72ef6b905dabafa88bcc50aaa5b8eb52f84ba /tests/settings_tests
parenta2e3f95b0937f3f1e4a479db219392eb6ded39f7 (diff)
Fixed #32304 -- Fixed prefixing STATIC_URL and MEDIA_URL by SCRIPT_NAME for absolute URLs with no domain.
Thanks Adam Hooper for the report. Regression in c574bec0929cd2527268c96a492d25223a9fd576.
Diffstat (limited to 'tests/settings_tests')
-rw-r--r--tests/settings_tests/tests.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/tests/settings_tests/tests.py b/tests/settings_tests/tests.py
index 1368b2ae18..f9f8bdb5ab 100644
--- a/tests/settings_tests/tests.py
+++ b/tests/settings_tests/tests.py
@@ -573,10 +573,12 @@ class MediaURLStaticURLPrefixTest(SimpleTestCase):
set_script_prefix(val)
def test_not_prefixed(self):
- # Don't add SCRIPT_NAME prefix to valid URLs, absolute paths or None.
+ # Don't add SCRIPT_NAME prefix to absolute paths, URLs, or None.
tests = (
'/path/',
'http://myhost.com/path/',
+ 'http://myhost/path/',
+ 'https://myhost/path/',
None,
)
for setting in ('MEDIA_URL', 'STATIC_URL'):