File tree Expand file tree Collapse file tree 3 files changed +31
-5
lines changed Expand file tree Collapse file tree 3 files changed +31
-5
lines changed Original file line number Diff line number Diff line change 45
45
46
46
SUPPORTED_HOST_KERNELS = ["4.14" , "5.10" , "6.1" ]
47
47
48
+ IMG_DIR = Path (DEFAULT_TEST_SESSION_ROOT_PATH ) / "img"
48
49
49
- ARTIFACT_DIR = (
50
- Path (__file__ ).joinpath ("../../../build/img" ).resolve () / platform .machine ()
51
- )
50
+ # fall-back to the local directory
51
+ if not IMG_DIR .exists ():
52
+ IMG_DIR = Path (__file__ ).joinpath ("../../../build/img" ).resolve ()
53
+
54
+ ARTIFACT_DIR = IMG_DIR / platform .machine ()
Original file line number Diff line number Diff line change @@ -624,14 +624,14 @@ cmd_test() {
624
624
--ulimit core=0 \
625
625
--ulimit nofile=4096:4096 \
626
626
--ulimit memlock=-1:-1 \
627
- --workdir " $CTR_FC_ROOT_DIR /tests " \
627
+ --workdir " $CTR_FC_ROOT_DIR " \
628
628
--cpuset-cpus=" $cpuset_cpus " \
629
629
--cpuset-mems=" $cpuset_mems " \
630
630
--env-file env.list \
631
631
-v /boot:/boot \
632
632
${ramdisk_args} \
633
633
-- \
634
- pytest " $@ "
634
+ ./tools/test.sh " $@ "
635
635
636
636
ret=$?
637
637
Original file line number Diff line number Diff line change
1
+ #! /bin/bash
2
+
3
+ # Copyright 2023 Amazon.com, Inc. or its affiliates. All Rights Reserved.
4
+ # SPDX-License-Identifier: Apache-2.0
5
+
6
+ # fail if we encounter an error, uninitialized variable or a pipe breaks
7
+ set -eu -o pipefail
8
+
9
+ TOOLS_DIR=$( dirname $0 )
10
+ source " $TOOLS_DIR /functions"
11
+
12
+ # Set our TMPDIR inside /srv, so all files created in the session end up in one
13
+ # place
14
+ say " Create TMPDIR in /srv"
15
+ export TMPDIR=/srv/tmp
16
+ mkdir -pv $TMPDIR
17
+
18
+ say " Copy CI artifacts to /srv, so hardlinks work"
19
+ cp -ruvf build/img /srv
20
+
21
+ cd tests
22
+ pytest " $@ "
23
+ exit $?
You can’t perform that action at this time.
0 commit comments