Skip to content

Commit 1fb019c

Browse files
authored
Fix a problem where ETR would not respect quotation marks (#64)
* Fix a problem where ETR would not respect quotation marks * Revert a change made to __init__
1 parent 9290d94 commit 1fb019c

File tree

5 files changed

+12
-9
lines changed

5 files changed

+12
-9
lines changed

src/etos_test_runner/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,9 @@
1818
import os
1919
import logging
2020
from importlib.metadata import version, PackageNotFoundError
21+
2122
from etos_lib.logging.logger import setup_logging
23+
2224
from etos_test_runner.lib.decrypt import decrypt
2325

2426
try:

src/etos_test_runner/lib/executor.sh

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -17,21 +17,21 @@
1717
eval "$(pyenv init -)"
1818
pyenv shell --unset
1919

20-
DIR=$(dirname $0)
20+
DIR="$(dirname "$0")"
2121
echo "Executing pre-execution script"
22-
cat $DIR/environ.sh
23-
if ! source $DIR/environ.sh ; then
22+
cat "$DIR/environ.sh"
23+
if ! source "$DIR/environ.sh" ; then
2424
echo Could not execute pre-execution script.
2525
exit 1
2626
fi
2727

2828
COMMAND=$1
2929
shift
30-
ARGS=$@
30+
ARGS=("$@")
3131

3232
echo "Environment used for tests"
3333
env | sort
3434

3535
echo "Executing:"
36-
echo $COMMAND $ARGS
37-
$COMMAND $ARGS
36+
echo "$COMMAND" "${ARGS[@]}"
37+
"$COMMAND" "${ARGS[@]}"

tests/scenarios/test_full_execution.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@
3434
echo ==== test_name_yo ====
3535
echo == STARTED ==
3636
echo == PASSED ==
37+
3738
exit 0
3839
"""
3940

@@ -97,7 +98,7 @@
9798
"log_area": {
9899
"provider_id": "default",
99100
"livelogs": "http://localhost/livelogs",
100-
"upload": {"url": "http://localhost/logs", "method": "POST"},
101+
"upload": {"url": "http://localhost/logs", "method": "PUT", "as_json": False},
101102
"logs": {},
102103
},
103104
}

tests/scenarios/test_no_detected_test_name.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@
9797
"log_area": {
9898
"provider_id": "default",
9999
"livelogs": "http://localhost/livelogs",
100-
"upload": {"url": "http://localhost/logs", "method": "POST"},
100+
"upload": {"url": "http://localhost/logs", "method": "PUT", "as_json": False},
101101
"logs": {},
102102
},
103103
}

tox.ini

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,4 +34,4 @@ commands =
3434
deps =
3535
pydocstyle
3636
commands =
37-
pydocstyle .
37+
pydocstyle src tests

0 commit comments

Comments
 (0)