Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
limbra
limbra
Commits
505cce24
Commit
505cce24
authored
Sep 09, 2016
by
LE GAC Renaud
Browse files
Update scripts/run to fix crashes running pytest behind a container.
parent
0edece57
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
6 deletions
+7
-6
scripts/run
scripts/run
+7
-6
No files found.
scripts/run
View file @
505cce24
...
...
@@ -163,7 +163,7 @@ def get_web2py(args):
if
out
:
for
line
in
out
.
split
(
"
\n
"
):
li
=
line
.
split
()
if
args
.
docker_container
==
li
[
-
1
]:
if
li
and
args
.
docker_container
==
li
[
-
1
]:
cmd
=
[
DOCKER
,
"exec"
,
"-it"
,
...
...
@@ -171,10 +171,10 @@ def get_web2py(args):
os
.
path
.
join
(
W2P_CNT
,
WEB2PY
)]
return
cmd
print
"
\n\t
web2py.py is not found !"
print
"
\t
D
irectory"
,
args
.
web2py_dir
,
"
d
on
't exists
!"
print
"
\t
Docker container"
,
args
.
docker_container
,
"
don't exist
!"
print
"
\t
Tune th
e option --web2py-dir
or
--docker-container.
\n
"
print
"
\n\t
web2py.py is not found
on the local host
!"
print
"
\t
No d
irectory"
,
args
.
web2py_dir
,
"on
the local host
!"
print
"
\t
Docker container"
,
args
.
docker_container
,
"
is not running
!"
print
"
\t
Start container or tun
e option --web2py-dir
,
--docker-container.
\n
"
sys
.
exit
(
1
)
...
...
@@ -345,11 +345,12 @@ def run_pytest(args):
"""
cmd
=
""
skip_options
=
(
"docker_container"
,
"func"
,
"path"
,
"shell"
,
"web2py_dir"
)
# collect active option
for
k
,
v
in
vars
(
args
).
iteritems
():
if
not
v
or
k
in
(
"func"
,
"path"
,
"shell"
):
if
(
not
v
)
or
(
k
in
skip_options
):
continue
elif
k
==
"capture"
:
...
...
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