Skip to content
Snippets Groups Projects
Commit e5883735 authored by Stéphane Diemer's avatar Stéphane Diemer
Browse files

Fixed warnings type in nginx vhost test.

parent 95544c63
No related branches found
No related tags found
No related merge requests found
...@@ -49,7 +49,7 @@ if os.path.exists('/etc/celerity/config.py'): ...@@ -49,7 +49,7 @@ if os.path.exists('/etc/celerity/config.py'):
resolution_ignored = conf.get('TESTER_VHOST_RESOLUTION_IGNORED', '').split(',') resolution_ignored = conf.get('TESTER_VHOST_RESOLUTION_IGNORED', '').split(',')
found = False found = False
errors = 0 errors = 0
warnings = False warnings = 0
for name in os.listdir(nginx_dir): for name in os.listdir(nginx_dir):
path = os.path.join(nginx_dir, name) path = os.path.join(nginx_dir, name)
with open(path, 'r') as fo: with open(path, 'r') as fo:
...@@ -71,7 +71,7 @@ for name in os.listdir(nginx_dir): ...@@ -71,7 +71,7 @@ for name in os.listdir(nginx_dir):
sys.stdout.write('Testing url "%s":\n' % url) sys.stdout.write('Testing url "%s":\n' % url)
if name.startswith('mediaserver') and url not in celerity_conf: if name.startswith('mediaserver') and url not in celerity_conf:
sys.stdout.write('Url "%s" not found in celerity conf; it should also be set in the MediaWorker.\n' % url) sys.stdout.write('Url "%s" not found in celerity conf; it should also be set in the MediaWorker.\n' % url)
warnings = True warnings += 1
# test domain IP # test domain IP
ip_error = None ip_error = None
ip_warning = None ip_warning = None
...@@ -128,7 +128,7 @@ for name in os.listdir(nginx_dir): ...@@ -128,7 +128,7 @@ for name in os.listdir(nginx_dir):
sys.stdout.write('.\n') sys.stdout.write('.\n')
if ip_warning: if ip_warning:
warnings +=1 warnings += 1
if ip_error or req_error: if ip_error or req_error:
errors += 1 errors += 1
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment