Tests: perl module.

This commit is contained in:
Andrey Zelenkov
2018-02-12 19:32:54 +03:00
parent 9646772a00
commit e2c3fa6304
15 changed files with 235 additions and 0 deletions

View File

@@ -292,3 +292,25 @@ class TestUnitControl(TestUnitHTTP):
sock_type='unix',
addr=self.testdir + '/control.unit.sock'
)['body'])
class TestUnitApplicationProto(TestUnitControl):
current_dir = os.path.dirname(os.path.abspath(__file__))
class TestUnitApplicationPerl(TestUnitApplicationProto):
def load(self, dir, name='psgi.pl'):
self.conf({
"listeners": {
"*:7080": {
"application": dir
}
},
"applications": {
dir: {
"type": "perl",
"processes": { "spare": 0 },
"working_directory": self.current_dir + '/perl/' + dir,
"script": self.current_dir + '/perl/' + dir + '/' + name
}
}
})