mirror of
https://github.com/bunkerity/bunkerized-nginx
synced 2023-12-13 21:30:18 +01:00
Fix children classes of Test
This commit is contained in:
parent
f4ce2c68f2
commit
f5fe685d42
4 changed files with 9 additions and 4 deletions
|
@ -28,6 +28,7 @@ class AutoconfTest(Test):
|
||||||
}
|
}
|
||||||
self._check_domains()
|
self._check_domains()
|
||||||
|
|
||||||
|
@staticmethod
|
||||||
def init():
|
def init():
|
||||||
try:
|
try:
|
||||||
if not Test.init():
|
if not Test.init():
|
||||||
|
@ -100,6 +101,7 @@ class AutoconfTest(Test):
|
||||||
return False
|
return False
|
||||||
return True
|
return True
|
||||||
|
|
||||||
|
@staticmethod
|
||||||
def end():
|
def end():
|
||||||
ret = True
|
ret = True
|
||||||
try:
|
try:
|
||||||
|
|
|
@ -25,6 +25,7 @@ class DockerTest(Test):
|
||||||
}
|
}
|
||||||
self._check_domains()
|
self._check_domains()
|
||||||
|
|
||||||
|
@staticmethod
|
||||||
def init():
|
def init():
|
||||||
try:
|
try:
|
||||||
if not Test.init():
|
if not Test.init():
|
||||||
|
|
|
@ -20,6 +20,7 @@ class KubernetesTest(Test):
|
||||||
r"app3\.example\.com": f"{Test.random_string(6)}.{getenv('TEST_DOMAIN3')}",
|
r"app3\.example\.com": f"{Test.random_string(6)}.{getenv('TEST_DOMAIN3')}",
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@staticmethod
|
||||||
def init():
|
def init():
|
||||||
try:
|
try:
|
||||||
if not Test.init():
|
if not Test.init():
|
||||||
|
@ -143,6 +144,7 @@ class KubernetesTest(Test):
|
||||||
return False
|
return False
|
||||||
return True
|
return True
|
||||||
|
|
||||||
|
@staticmethod
|
||||||
def end():
|
def end():
|
||||||
ret = True
|
ret = True
|
||||||
try:
|
try:
|
||||||
|
|
|
@ -27,9 +27,9 @@ class Test(ABC):
|
||||||
f"instiantiated with {len(tests)} tests and timeout of {timeout}s for {self._name}",
|
f"instiantiated with {len(tests)} tests and timeout of {timeout}s for {self._name}",
|
||||||
)
|
)
|
||||||
|
|
||||||
# Class method
|
|
||||||
# called once before running all the different tests for a given integration
|
# called once before running all the different tests for a given integration
|
||||||
def init(self):
|
@staticmethod
|
||||||
|
def init():
|
||||||
try:
|
try:
|
||||||
if not isdir("/tmp/bw-data"):
|
if not isdir("/tmp/bw-data"):
|
||||||
mkdir("/tmp/bw-data")
|
mkdir("/tmp/bw-data")
|
||||||
|
@ -46,8 +46,8 @@ class Test(ABC):
|
||||||
return True
|
return True
|
||||||
|
|
||||||
# Class method
|
# Class method
|
||||||
# called once all tests ended
|
@staticmethod
|
||||||
def end(self):
|
def end():
|
||||||
return True
|
return True
|
||||||
|
|
||||||
# helper to check domains
|
# helper to check domains
|
||||||
|
|
Loading…
Reference in a new issue