diff options
Diffstat (limited to 'test/unit/applications/lang/python.py')
-rw-r--r-- | test/unit/applications/lang/python.py | 22 |
1 files changed, 13 insertions, 9 deletions
diff --git a/test/unit/applications/lang/python.py b/test/unit/applications/lang/python.py index 374b0f9c..20d4f257 100644 --- a/test/unit/applications/lang/python.py +++ b/test/unit/applications/lang/python.py @@ -34,20 +34,24 @@ class TestApplicationPython(TestApplicationProto): script_path = '/app/python/' + name + app = { + "type": self.get_application_type(), + "processes": kwargs.pop('processes', {"spare": 0}), + "path": script_path, + "working_directory": script_path, + "module": module, + } + + for attr in ('callable', 'home', 'limits', 'path', 'threads'): + if attr in kwargs: + app[attr] = kwargs.pop(attr) + self._load_conf( { "listeners": { "*:7080": {"pass": "applications/" + quote(name, '')} }, - "applications": { - name: { - "type": self.get_application_type(), - "processes": {"spare": 0}, - "path": script_path, - "working_directory": script_path, - "module": module, - } - }, + "applications": {name: app}, }, **kwargs ) |