Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
slapos-caddy
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Guillaume Hervier
slapos-caddy
Commits
67d4b057
Commit
67d4b057
authored
Apr 11, 2017
by
Łukasz Nowak
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
WIP: Improve even more communication and status
parent
bef98662
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
5 deletions
+10
-5
software/cdn-test/runTestSuite.py
software/cdn-test/runTestSuite.py
+10
-5
No files found.
software/cdn-test/runTestSuite.py
View file @
67d4b057
...
...
@@ -107,8 +107,8 @@ def main():
result_file
=
os
.
path
.
abspath
(
result_file
)
status_dict
[
'command'
]
=
result_file
result
=
open
(
result_file
).
read
()
print
(
try_info
+
'Analysis of result %r:'
%
(
result_file
,))
print
(
try_info
+
result
)
print
(
try_info
+
'
Analysis of result %r:'
%
(
result_file
,))
print
(
try_info
+
' '
+
result
)
if
'FATAL: all hosts have already failed -- aborting'
in
result
:
# failed
status_dict
.
update
(
...
...
@@ -118,6 +118,8 @@ def main():
error_count
=
0
)
finished
=
False
status_dict
[
'stdout'
]
=
'Build not yet successful.'
print
(
try_info
+
' %r: Found not yet finished run.'
%
(
result_file
,))
elif
"
\
"
msg
\
"
:
\
"
[u'Build successful, connect to:', u'"
in
result
:
# success
status_dict
.
update
(
...
...
@@ -127,6 +129,8 @@ def main():
error_count
=
0
)
finished
=
True
print
(
try_info
+
' %r: Found finished successful run.'
%
(
result_file
,))
status_dict
[
'stdout'
]
=
'Build successful.'
break
else
:
# unknown
...
...
@@ -138,13 +142,14 @@ def main():
)
status_dict
[
'stdout'
]
=
\
'Cannot find success or failure result in the output'
print
(
try_info
+
' %r: Found unknown run.'
%
(
result_file
,))
finished
=
False
# send only part of the result
status_dict
[
'stderr'
]
=
result
[
-
8192
:]
if
finished
:
break
if
try_num
>
try_amount
:
print
(
try_info
+
' Time exceeded, data not found.'
)
msg
=
try_info
+
' Time exceeded, success not found.'
print
(
msg
)
status_dict
[
'stderr'
]
=
msg
break
try_num
+=
1
sleep
(
10
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment