Skip to content

Commit ffe6c67

Browse files
committed
WIP
1 parent e242dec commit ffe6c67

File tree

3 files changed

+32
-0
lines changed

3 files changed

+32
-0
lines changed

.ci/fifo_read.py

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
import os
2+
import sys
3+
import tempfile
4+
5+
if __name__ == "__main__":
6+
while True:
7+
fifo_path = sys.argv[1]
8+
with open(sys.argv[1], 'rb') as fifo:
9+
filename, ext = os.path.splitext(os.path.basename(fifo_path))
10+
fd, _ = tempfile.mkstemp(
11+
suffix=ext, prefix=f"{filename}.", dir=os.path.dirname(fifo_path))
12+
with os.fdopen(fd, 'wb') as out:
13+
out.write(fifo.read())
14+

.ci/monolithic-linux.sh

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ MONOREPO_ROOT="${MONOREPO_ROOT:="$(git rev-parse --show-toplevel)"}"
2020
BUILD_DIR="${BUILD_DIR:=${MONOREPO_ROOT}/build}"
2121
INSTALL_DIR="${BUILD_DIR}/install"
2222
rm -rf "${BUILD_DIR}"
23+
mkdir -p ${BUILD_DIR}
2324

2425
ccache --zero-stats
2526

@@ -28,7 +29,15 @@ if [[ -n "${CLEAR_CACHE:-}" ]]; then
2829
ccache --clear
2930
fi
3031

32+
# This will capture each time lit results out results and put each in its own file.
33+
test_result_path="${BUILD_DIR}"/test-results.xml
34+
mkfifo $test_result_path
35+
python3 "${MONOREPO_ROOT}"/.ci/fifo_read.py $test_result_path &
36+
fifo_pid=$!
37+
3138
function at-exit {
39+
kill $fifo_pid
40+
rm $test_result_path
3241
python3 "${MONOREPO_ROOT}"/.ci/generate_test_report.py ":linux: Linux x64 Test Results" \
3342
"linux-x64-test-results" "${BUILD_DIR}"/test-results*.xml
3443

.ci/monolithic-windows.sh

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,14 +20,23 @@ MONOREPO_ROOT="${MONOREPO_ROOT:="$(git rev-parse --show-toplevel)"}"
2020
BUILD_DIR="${BUILD_DIR:=${MONOREPO_ROOT}/build}"
2121

2222
rm -rf "${BUILD_DIR}"
23+
mkdir -p ${BUILD_DIR}
2324

2425
if [[ -n "${CLEAR_CACHE:-}" ]]; then
2526
echo "clearing sccache"
2627
rm -rf "$SCCACHE_DIR"
2728
fi
2829

30+
# This will capture each time lit results out results and put each in its own file.
31+
test_result_path="${BUILD_DIR}"/test-results.xml
32+
mkfifo $test_result_path
33+
python "${MONOREPO_ROOT}"/.ci/fifo_read.py $test_result_path &
34+
fifo_pid=$!
35+
2936
sccache --zero-stats
3037
function at-exit {
38+
kill $fifo_pid
39+
rm $test_result_path
3140
python "${MONOREPO_ROOT}"/.ci/generate_test_report.py ":windows: Windows x64 Test Results" \
3241
"windows-x64-test-results" "${BUILD_DIR}"/test-results*.xml
3342

0 commit comments

Comments
 (0)