Skip to content
Snippets Groups Projects

Resolve "Apps sollen mit Alias an Hub angemeldet werden können"

Merged slobinger requested to merge 29-alias-for-apps into master
1 file
+ 7
5
Compare changes
  • Side-by-side
  • Inline
+ 7
5
@@ -33,12 +33,14 @@ class CaseSAMSHubWithThreadedAPI(unittest.TestCase):
@@ -33,12 +33,14 @@ class CaseSAMSHubWithThreadedAPI(unittest.TestCase):
self.hub.addApp(
self.hub.addApp(
SAMSApp(name = 'test',manifest = manifest, langDict={'de':{}})
SAMSApp(name = 'test',manifest = manifest, langDict={'de':{}})
)
)
self.hub.addApp(
testApp = SAMSApp(name = 'test.app', manifest = manifest, langDict={'de':{}})
SAMSApp(name = 'test.app', manifest = manifest, langDict={'de':{}})
self.hub.addApp(app = testApp)
)
self.hub.addApp(app = testApp, alias = 'test')
with self.hub.flaskApp.test_client() as client:
with self.hub.flaskApp.test_client() as client:
self.assertIs(client.get(path='/api/hello').status_code, 200)
for urlPrefix in ('', '/test.app', '/test'):
self.assertIs(client.get(path='/test.app/api/hello').status_code, 200)
with self.subTest(urlPrefix):
 
self.assertIs(client.get(
 
path = urlPrefix + '/api/hello').status_code, 200)
class CaseSAMSHubWithMainApp(unittest.TestCase):
class CaseSAMSHubWithMainApp(unittest.TestCase):
Loading