go.py (1208:220272baa960) go.py (1303:248eeec4c272)
1import os
2from subprocess import Popen
3from unit.applications.proto import TestApplicationProto
4
5
6class TestApplicationGo(TestApplicationProto):
7 @classmethod
8 def setUpClass(cls, complete_check=True):

--- 30 unchanged lines hidden (view full) ---

39
40 process.communicate()
41
42 except:
43 return None
44
45 return process
46
1import os
2from subprocess import Popen
3from unit.applications.proto import TestApplicationProto
4
5
6class TestApplicationGo(TestApplicationProto):
7 @classmethod
8 def setUpClass(cls, complete_check=True):

--- 30 unchanged lines hidden (view full) ---

39
40 process.communicate()
41
42 except:
43 return None
44
45 return process
46
47 def load(self, script, name='app'):
47 def load(self, script, name='app', **kwargs):
48 self.prepare_env(script, name)
49
50 self._load_conf(
51 {
52 "listeners": {"*:7080": {"pass": "applications/" + script}},
53 "applications": {
54 script: {
55 "type": "external",
56 "processes": {"spare": 0},
57 "working_directory": self.current_dir
58 + "/go/"
59 + script,
60 "executable": self.testdir + "/go/" + name,
61 }
62 },
48 self.prepare_env(script, name)
49
50 self._load_conf(
51 {
52 "listeners": {"*:7080": {"pass": "applications/" + script}},
53 "applications": {
54 script: {
55 "type": "external",
56 "processes": {"spare": 0},
57 "working_directory": self.current_dir
58 + "/go/"
59 + script,
60 "executable": self.testdir + "/go/" + name,
61 }
62 },
63 }
63 },
64 **kwargs
64 )
65 )