summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--test/test_basic.py28
-rw-r--r--test/test_configuration.py10
2 files changed, 19 insertions, 19 deletions
diff --git a/test/test_basic.py b/test/test_basic.py
index b643ee21..e6a5c6e8 100644
--- a/test/test_basic.py
+++ b/test/test_basic.py
@@ -60,22 +60,22 @@ class TestUnitBasic(unit.TestUnitControl):
self.assertEqual(self.get('/applications/app/workers'), 1,
'python applications workers')
- self.put('/listeners', '{"*:8080":{"application":"app"}}')
+ self.put('/listeners', '{"*:7080":{"application":"app"}}')
self.assertEqual(self.get()['listeners'],
- {"*:8080":{"application":"app"}}, 'python listeners')
+ {"*:7080":{"application":"app"}}, 'python listeners')
self.assertEqual(self.get('/listeners'),
- {"*:8080":{"application":"app"}}, 'python listeners prefix')
- self.assertEqual(self.get('/listeners/*:8080'),
+ {"*:7080":{"application":"app"}}, 'python listeners prefix')
+ self.assertEqual(self.get('/listeners/*:7080'),
{"application":"app"}, 'python listeners prefix 2')
- self.assertEqual(self.get('/listeners/*:8080/application'), 'app',
+ self.assertEqual(self.get('/listeners/*:7080/application'), 'app',
'python listeners application')
def test_put(self):
self.put('/', """
{
"listeners": {
- "*:8080": {
+ "*:7080": {
"application": "app"
}
},
@@ -92,7 +92,7 @@ class TestUnitBasic(unit.TestUnitControl):
resp = self.get()
- self.assertEqual(resp['listeners'], {"*:8080":{"application":"app"}},
+ self.assertEqual(resp['listeners'], {"*:7080":{"application":"app"}},
'put listeners')
self.assertEqual(resp['applications'],
@@ -106,18 +106,18 @@ class TestUnitBasic(unit.TestUnitControl):
},
'put applications')
- self.put('/listeners', '{"*:8081":{"application":"app"}}')
+ self.put('/listeners', '{"*:7081":{"application":"app"}}')
self.assertEqual(self.get('/listeners'),
- {"*:8081": {"application":"app"}}, 'put listeners prefix')
+ {"*:7081": {"application":"app"}}, 'put listeners prefix')
- self.put('/listeners/*:8082', '{"application":"app"}')
+ self.put('/listeners/*:7082', '{"application":"app"}')
self.assertEqual(self.get('/listeners'),
{
- "*:8081": {
+ "*:7081": {
"application": "app"
},
- "*:8082": {
+ "*:7082": {
"application": "app"
}
},
@@ -135,7 +135,7 @@ class TestUnitBasic(unit.TestUnitControl):
self.put('/', """
{
"listeners": {
- "*:8080": {
+ "*:7080": {
"application": "app"
}
},
@@ -152,7 +152,7 @@ class TestUnitBasic(unit.TestUnitControl):
self.assertIn('error', self.delete('/applications/app'),
'delete app before listener')
- self.assertIn('success', self.delete('/listeners/*:8080'),
+ self.assertIn('success', self.delete('/listeners/*:7080'),
'delete listener')
self.assertIn('success', self.delete('/applications/app'),
'delete app after listener')
diff --git a/test/test_configuration.py b/test/test_configuration.py
index 863250cd..7d487e49 100644
--- a/test/test_configuration.py
+++ b/test/test_configuration.py
@@ -91,7 +91,7 @@ class TestUnitConfiguration(unit.TestUnitControl):
def test_json_listeners(self):
self.assertIn('error', self.put('/listeners',
- '{"*:8080":{"application":"app"}}'), 'listeners no app')
+ '{"*:7080":{"application":"app"}}'), 'listeners no app')
self.put('/applications', """
{
@@ -105,18 +105,18 @@ class TestUnitConfiguration(unit.TestUnitControl):
""")
self.assertIn('success', self.put('/listeners',
- '{"*:8080":{"application":"app"}}'), 'listeners wildcard')
+ '{"*:7080":{"application":"app"}}'), 'listeners wildcard')
self.assertIn('success', self.put('/listeners',
- '{"127.0.0.1:8081":{"application":"app"}}'), 'listeners explicit')
+ '{"127.0.0.1:7081":{"application":"app"}}'), 'listeners explicit')
self.assertIn('success', self.put('/listeners',
- '{"[::1]:8082":{"application":"app"}}'), 'listeners explicit ipv6')
+ '{"[::1]:7082":{"application":"app"}}'), 'listeners explicit ipv6')
self.assertIn('error', self.put('/listeners',
'{"127.0.0.1":{"application":"app"}}'), 'listeners no port')
@unittest.skip("TODO")
def test_broken(self):
self.assertIn('error', self.put('/', '00'), 'leading zero')
- self.assertIn('error', self.put('/listeners', '{"*:8080":{}}'),
+ self.assertIn('error', self.put('/listeners', '{"*:7080":{}}'),
'listener empty')
self.assertIn('error', self.put('/applications', '"type":"python"'),
'application type only')