diff options
author | Andrei Zeliankou <zelenkov@nginx.com> | 2021-12-12 21:36:44 +0000 |
---|---|---|
committer | Andrei Zeliankou <zelenkov@nginx.com> | 2021-12-12 21:36:44 +0000 |
commit | 9bea8c452ffea1d9ff78a1bc3ce5c4d2f0d6b95f (patch) | |
tree | 17be138c1c40cbbc9be3726a3d35b0a114b94b0d /test | |
parent | 4b3efcea0dfcc842fb1a0f62b610652323844d35 (diff) | |
download | unit-9bea8c452ffea1d9ff78a1bc3ce5c4d2f0d6b95f.tar.gz unit-9bea8c452ffea1d9ff78a1bc3ce5c4d2f0d6b95f.tar.bz2 |
Tests: fixed type of applications.
Diffstat (limited to 'test')
-rw-r--r-- | test/test_asgi_lifespan.py | 2 | ||||
-rw-r--r-- | test/test_asgi_targets.py | 2 | ||||
-rw-r--r-- | test/test_java_application.py | 2 | ||||
-rw-r--r-- | test/test_php_application.py | 6 | ||||
-rw-r--r-- | test/test_php_targets.py | 4 | ||||
-rw-r--r-- | test/test_proxy.py | 10 | ||||
-rw-r--r-- | test/test_python_targets.py | 2 | ||||
-rw-r--r-- | test/test_routing.py | 16 | ||||
-rw-r--r-- | test/test_upstreams_rr.py | 2 |
9 files changed, 23 insertions, 23 deletions
diff --git a/test/test_asgi_lifespan.py b/test/test_asgi_lifespan.py index 912d0d85..dcdd107d 100644 --- a/test/test_asgi_lifespan.py +++ b/test/test_asgi_lifespan.py @@ -67,7 +67,7 @@ class TestASGILifespan(TestApplicationPython): ], "applications": { "targets": { - "type": "python", + "type": self.get_application_type(), "processes": {"spare": 0}, "working_directory": option.test_dir + "/python/lifespan/empty", diff --git a/test/test_asgi_targets.py b/test/test_asgi_targets.py index b9489cd3..73929783 100644 --- a/test/test_asgi_targets.py +++ b/test/test_asgi_targets.py @@ -28,7 +28,7 @@ class TestASGITargets(TestApplicationPython): ], "applications": { "targets": { - "type": "python", + "type": self.get_application_type(), "processes": {"spare": 0}, "working_directory": option.test_dir + "/python/targets/", diff --git a/test/test_java_application.py b/test/test_java_application.py index 3fd5c26e..aba49e48 100644 --- a/test/test_java_application.py +++ b/test/test_java_application.py @@ -22,7 +22,7 @@ class TestJavaApplication(TestApplicationJava): "listeners": {"*:7080": {"pass": "applications/app"}}, "applications": { "app": { - "type": "java", + "type": self.get_application_type(), "processes": 1, "working_directory": option.test_dir + "/java/empty", "webapp": temp_dir + "/java", diff --git a/test/test_php_application.py b/test/test_php_application.py index 97bb9437..e6540318 100644 --- a/test/test_php_application.py +++ b/test/test_php_application.py @@ -600,7 +600,7 @@ opcache.preload_user = %(user)s "listeners": {"*:7080": {"pass": "applications/script"}}, "applications": { "script": { - "type": "php", + "type": self.get_application_type(), "processes": {"spare": 0}, "root": option.test_dir + "/php/script", "script": "phpinfo.php", @@ -620,7 +620,7 @@ opcache.preload_user = %(user)s "listeners": {"*:7080": {"pass": "applications/phpinfo"}}, "applications": { "phpinfo": { - "type": "php", + "type": self.get_application_type(), "processes": {"spare": 0}, "root": option.test_dir + "/php/phpinfo", } @@ -647,7 +647,7 @@ opcache.preload_user = %(user)s "listeners": {"*:7080": {"pass": "applications/phpinfo"}}, "applications": { "phpinfo": { - "type": "php", + "type": self.get_application_type(), "processes": {"spare": 0}, "root": new_root, "working_directory": new_root, diff --git a/test/test_php_targets.py b/test/test_php_targets.py index 76326131..918c5fda 100644 --- a/test/test_php_targets.py +++ b/test/test_php_targets.py @@ -22,7 +22,7 @@ class TestPHPTargets(TestApplicationPHP): ], "applications": { "targets": { - "type": "php", + "type": self.get_application_type(), "processes": {"spare": 0}, "targets": { "1": { @@ -66,7 +66,7 @@ class TestPHPTargets(TestApplicationPHP): }, "applications": { "targets": { - "type": "php", + "type": self.get_application_type(), "processes": {"spare": 0}, "targets": { "default": { diff --git a/test/test_proxy.py b/test/test_proxy.py index 553cb07c..9245ef1c 100644 --- a/test/test_proxy.py +++ b/test/test_proxy.py @@ -72,7 +72,7 @@ Content-Length: 10 "routes": [{"action": {"proxy": "http://127.0.0.1:7081"}}], "applications": { "mirror": { - "type": "python", + "type": self.get_application_type(), "processes": {"spare": 0}, "path": option.test_dir + "/python/mirror", "working_directory": option.test_dir @@ -80,7 +80,7 @@ Content-Length: 10 "module": "wsgi", }, "custom_header": { - "type": "python", + "type": self.get_application_type(), "processes": {"spare": 0}, "path": option.test_dir + "/python/custom_header", "working_directory": option.test_dir @@ -88,7 +88,7 @@ Content-Length: 10 "module": "wsgi", }, "delayed": { - "type": "python", + "type": self.get_application_type(), "processes": {"spare": 0}, "path": option.test_dir + "/python/delayed", "working_directory": option.test_dir @@ -123,7 +123,7 @@ Content-Length: 10 }, "applications": { "mirror": { - "type": "python", + "type": self.get_application_type(), "processes": {"spare": 0}, "path": option.test_dir + "/python/mirror", "working_directory": option.test_dir @@ -499,7 +499,7 @@ Content-Length: 10 "routes": [{"action": {"proxy": "http://127.0.0.1:7082"}}], "applications": { "mirror": { - "type": "python", + "type": self.get_application_type(), "processes": {"spare": 0}, "path": option.test_dir + "/python/mirror", "working_directory": option.test_dir diff --git a/test/test_python_targets.py b/test/test_python_targets.py index e5dca870..8e9ecb87 100644 --- a/test/test_python_targets.py +++ b/test/test_python_targets.py @@ -21,7 +21,7 @@ class TestPythonTargets(TestApplicationPython): ], "applications": { "targets": { - "type": "python", + "type": self.get_application_type(), "working_directory": option.test_dir + "/python/targets/", "path": option.test_dir + '/python/targets/', diff --git a/test/test_routing.py b/test/test_routing.py index 167d2640..a45d0309 100644 --- a/test/test_routing.py +++ b/test/test_routing.py @@ -1,10 +1,10 @@ # -*- coding: utf-8 -*- import pytest -from unit.applications.proto import TestApplicationProto +from unit.applications.lang.python import TestApplicationPython from unit.option import option -class TestRouting(TestApplicationProto): +class TestRouting(TestApplicationPython): prerequisites = {'modules': {'python': 'any'}} def setup_method(self): @@ -289,7 +289,7 @@ class TestRouting(TestApplicationProto): "listeners": {"*:7080": {"pass": "applications/" + path}}, "applications": { name: { - "type": "python", + "type": self.get_application_type(), "processes": {"spare": 0}, "path": option.test_dir + '/python/empty', "working_directory": option.test_dir @@ -313,7 +313,7 @@ class TestRouting(TestApplicationProto): "listeners": {"*:7080": {"pass": "applications/" + path}}, "applications": { name: { - "type": "python", + "type": self.get_application_type(), "processes": {"spare": 0}, "path": option.test_dir + '/python/empty', "working_directory": option.test_dir @@ -333,7 +333,7 @@ class TestRouting(TestApplicationProto): "listeners": {"*:7081": {"pass": "applications/empty"}}, "applications": { "empty": { - "type": "python", + "type": self.get_application_type(), "processes": {"spare": 0}, "path": option.test_dir + '/python/empty', "working_directory": option.test_dir + '/python/empty', @@ -387,7 +387,7 @@ class TestRouting(TestApplicationProto): { "applications": { "app": { - "type": "python", + "type": self.get_application_type(), "processes": {"spare": 0}, "path": "/app", "module": "wsgi", @@ -430,7 +430,7 @@ class TestRouting(TestApplicationProto): { "applications": { "app": { - "type": "python", + "type": self.get_application_type(), "processes": {"spare": 0}, "path": "/app", "module": "wsgi", @@ -476,7 +476,7 @@ class TestRouting(TestApplicationProto): "routes": [{"action": {"proxy": "http://127.0.0.1:7081"}}], "applications": { "app": { - "type": "python", + "type": self.get_application_type(), "processes": {"spare": 0}, "path": "/app", "module": "wsgi", diff --git a/test/test_upstreams_rr.py b/test/test_upstreams_rr.py index 163eb646..4cb6bb2e 100644 --- a/test/test_upstreams_rr.py +++ b/test/test_upstreams_rr.py @@ -274,7 +274,7 @@ Connection: close ], "applications": { "delayed": { - "type": "python", + "type": self.get_application_type(), "processes": {"spare": 0}, "path": option.test_dir + "/python/delayed", "working_directory": option.test_dir |