mirror of
https://expo.survex.com/repositories/troggle/.git
synced 2024-11-25 08:41:51 +00:00
fix end slash issue
This commit is contained in:
parent
b4abd7b6bc
commit
dc3379c186
@ -65,7 +65,7 @@ We are now using Django 2.2.19
|
|||||||
|
|
||||||
Read this: https://docs.djangoproject.com/en/3.0/topics/install/
|
Read this: https://docs.djangoproject.com/en/3.0/topics/install/
|
||||||
|
|
||||||
We are installing with python3.7.3
|
We are installing with python3.7
|
||||||
Also : https://linuxize.com/post/how-to-install-pip-on-ubuntu-20.04/ ]
|
Also : https://linuxize.com/post/how-to-install-pip-on-ubuntu-20.04/ ]
|
||||||
|
|
||||||
Install Django using pip, not with apt, on your test system.
|
Install Django using pip, not with apt, on your test system.
|
||||||
|
@ -401,6 +401,16 @@ class PageTests(TestCase):
|
|||||||
self.assertIsNotNone(phmatch, "Failed to find expected text: '" + ph +"'")
|
self.assertIsNotNone(phmatch, "Failed to find expected text: '" + ph +"'")
|
||||||
|
|
||||||
def test_page_dwgallfiles_empty(self):
|
def test_page_dwgallfiles_empty(self):
|
||||||
|
# this gets an empty page as the database has not been loaded
|
||||||
|
response = self.client.get('/dwgfiles')
|
||||||
|
self.assertEqual(response.status_code, 200)
|
||||||
|
content = response.content.decode()
|
||||||
|
for ph in [ r'All Tunnel and Therion files',
|
||||||
|
r'<th>Scans folder</th><th>Scan files</th><th>Frames</th></tr>']:
|
||||||
|
phmatch = re.search(ph, content)
|
||||||
|
self.assertIsNotNone(phmatch, "Failed to find expected text: '" + ph +"'")
|
||||||
|
|
||||||
|
def test_page_dwgallfiles_empty_slash(self):
|
||||||
# this gets an empty page as the database has not been loaded
|
# this gets an empty page as the database has not been loaded
|
||||||
response = self.client.get('/dwgfiles/')
|
response = self.client.get('/dwgfiles/')
|
||||||
self.assertEqual(response.status_code, 200)
|
self.assertEqual(response.status_code, 200)
|
||||||
|
1
urls.py
1
urls.py
@ -157,6 +157,7 @@ trogglepatterns = [
|
|||||||
|
|
||||||
# The tunnel and therion drawings files pages
|
# The tunnel and therion drawings files pages
|
||||||
path('dwgfiles', dwgallfiles, name="dwgallfiles"),
|
path('dwgfiles', dwgallfiles, name="dwgallfiles"),
|
||||||
|
path('dwgfiles/', dwgallfiles, name="dwgallfiles"),
|
||||||
path('dwgdataraw/<path:path>', dwgfilesingle, name="dwgfilesingle"),
|
path('dwgdataraw/<path:path>', dwgfilesingle, name="dwgfilesingle"),
|
||||||
# path('dwgdataraw/<path:path>/upload', dwgfileupload, name="dwgfileupload"), # Not working
|
# path('dwgdataraw/<path:path>/upload', dwgfileupload, name="dwgfileupload"), # Not working
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user