Skip to content

Commit 475a17f

Browse files
authored
Fix the directory that Java assets get copied to (#173)
* Also add logcat.py back in as a background task
1 parent 7c1c71f commit 475a17f

8 files changed

Lines changed: 34 additions & 22 deletions

File tree

environment/aws/topology_setup/test_server_platforms/java_register.py

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -258,12 +258,7 @@ def _copy_dataset(self) -> None:
258258
# and instead only copy the one that is going to be built
259259
# so that way there is no need to keep a manual list of versions
260260
# here.
261-
dest_dir = (
262-
JAK_TEST_SERVER_DIR
263-
/ self.test_server_path
264-
/ "assets"
265-
/ self.dataset_version
266-
)
261+
dest_dir = JAK_TEST_SERVER_DIR / "assets" / self.dataset_version
267262
dest_dir.mkdir(0o755, parents=True, exist_ok=True)
268263
copy_dataset(dest_dir, self.dataset_version)
269264

jenkins/pipelines/android/android_teardown.sh

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,12 @@
22

33
SCRIPT_DIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )
44

5+
# kill logcat
6+
logcat_pid=$(cat $SCRIPT_DIR/logcat.pid)
7+
if [ -n "$logcat_pid" ]; then
8+
kill $logcat_pid
9+
fi
10+
511
export PYTHONPATH=$SCRIPT_DIR/../../../
612
pushd $SCRIPT_DIR/../../../environment/aws
713
python3 -m venv venv

jenkins/pipelines/android/android_tests.sh

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
1-
#!/bin/bash
1+
#!/bin/bash -e
22
# Build the Android test server, deploy it, and run the tests
33

4+
trap 'echo "$BASH_COMMAND (line $LINENO) failed, exiting..."; exit 1' ERR
5+
46
BUILD_TOOLS_VERSION='34.0.0'
57
SDK_MGR="${ANDROID_HOME}/cmdline-tools/latest/bin/sdkmanager --channel=1"
68
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )"
@@ -41,11 +43,10 @@ else
4143
fi
4244
deactivate
4345

44-
# The following appears to be incomplete as it hangs the script here...
45-
# echo "Start logcat"
46-
# pushd $SCRIPT_DIR
47-
# python3 logcat.py
48-
# echo $! > logcat.pid
46+
echo "Start logcat"
47+
pushd $SCRIPT_DIR
48+
python3 logcat.py &
49+
echo $! > logcat.pid
4950

5051
pushd $SCRIPT_DIR/../../../tests/dev_e2e > /dev/null
5152
rm -rf venv http_log testserver.log
@@ -56,7 +57,3 @@ pip install -r requirements.txt
5657
echo "Run the tests"
5758
adb shell input keyevent KEYCODE_WAKEUP
5859
pytest --maxfail=7 -W ignore::DeprecationWarning --config config.json
59-
60-
echo "Tests complete: $STATUS"
61-
exit $STATUS
62-

jenkins/pipelines/c/run_test.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
#!/bin/bash -e
22

3+
trap 'echo "$BASH_COMMAND (line $LINENO) failed, exiting..."; exit 1' ERR
4+
35
SCRIPT_DIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )
46

57
function usage() {

jenkins/pipelines/dotnet/run_test.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
#!/bin/bash -e
22

3+
trap 'echo "$BASH_COMMAND (line $LINENO) failed, exiting..."; exit 1' ERR
4+
35
SCRIPT_DIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )
46

57
function usage() {

jenkins/pipelines/ios/test.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
#!/bin/bash -e
22

3+
trap 'echo "$BASH_COMMAND (line $LINENO) failed, exiting..."; exit 1' ERR
4+
35
EDITION=${1}
46
CBL_VERSION=${2}
57
CBL_BLD_NUM=${3}

jenkins/pipelines/java/desktop/run_test.sh

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
#!/bin/bash -e
22

3+
trap 'echo "$BASH_COMMAND (line $LINENO) failed, exiting..."; exit 1' ERR
4+
35
SCRIPT_DIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )
6+
ROOT_DIR=$SCRIPT_DIR/../../../..
7+
SHARED_DIR="${SCRIPT_DIR}/../../shared"
48

59
function usage() {
610
echo "Usage: $0 <version> <dataset_version> <platform> <sgw_version> [private_key_path]"
@@ -23,18 +27,18 @@ cbl_version=$1
2327
dataset_version=$2
2428
sgw_version=$3
2529

26-
source $SCRIPT_DIR/../shared/check_python_version.sh
30+
source $SHARED_DIR/check_python_version.sh
2731

2832
create_venv venv
2933
source venv/bin/activate
30-
pip install -r $SCRIPT_DIR/../../../../environment/aws/requirements.txt
34+
pip install -r $ROOT_DIR/environment/aws/requirements.txt
3135
if [ -n "$private_key_path" ]; then
3236
python3 $SCRIPT_DIR/setup_test.py $cbl_version $dataset_version $sgw_version --private_key $private_key_path
3337
else
3438
python3 $SCRIPT_DIR/setup_test.py $cbl_version $dataset_version $sgw_version
3539
fi
3640

37-
pushd $SCRIPT_DIR/../../../../tests/dev_e2e
41+
pushd $ROOT_DIR/tests/dev_e2e
3842
pip install -r requirements.txt
3943
pytest --maxfail=7 -W ignore::DeprecationWarning --config config.json
4044
deactivate

jenkins/pipelines/java/webservice/run_test.sh

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
#!/bin/bash -e
22

3+
trap 'echo "$BASH_COMMAND (line $LINENO) failed, exiting..."; exit 1' ERR
4+
35
SCRIPT_DIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )
6+
ROOT_DIR=$SCRIPT_DIR/../../../..
7+
SHARED_DIR="${SCRIPT_DIR}/../../shared"
48

59
function usage() {
610
echo "Usage: $0 <version> <dataset_version> <sgw_version> [private_key_path]"
@@ -23,18 +27,18 @@ cbl_version=$1
2327
dataset_version=$2
2428
sgw_version=$3
2529

26-
source $SCRIPT_DIR/../shared/check_python_version.sh
30+
source $SHARED_DIR/check_python_version.sh
2731

2832
create_venv venv
2933
source venv/bin/activate
30-
pip install -r $SCRIPT_DIR/../../../../environment/aws/requirements.txt
34+
pip install -r $ROOT_DIR/environment/aws/requirements.txt
3135
if [ -n "$private_key_path" ]; then
3236
python3 $SCRIPT_DIR/setup_test.py $cbl_version $dataset_version $sgw_version --private_key $private_key_path
3337
else
3438
python3 $SCRIPT_DIR/setup_test.py $cbl_version $dataset_version $sgw_version
3539
fi
3640

37-
pushd $SCRIPT_DIR/../../../../tests/dev_e2e
41+
pushd $ROOT_DIR/tests/dev_e2e
3842
pip install -r requirements.txt
3943
pytest --maxfail=7 -W ignore::DeprecationWarning --config config.json
4044
deactivate

0 commit comments

Comments
 (0)