diff --git a/docker/test/fasttest/run.sh b/docker/test/fasttest/run.sh index e0e30a63bb4..3ed0c4df093 100755 --- a/docker/test/fasttest/run.sh +++ b/docker/test/fasttest/run.sh @@ -194,7 +194,12 @@ function build { ( cd "$FASTTEST_BUILD" - time ninja clickhouse-bundle 2>&1 | ts '%Y-%m-%d %H:%M:%S' | tee "$FASTTEST_OUTPUT/build_log.txt" + TIMEFORMAT=$'\nreal\t%3R\nuser\t%3U\nsys\t%3S' + ( time ninja clickhouse-bundle) |& ts '%Y-%m-%d %H:%M:%S' | tee "$FASTTEST_OUTPUT/build_log.txt" + BUILD_SECONDS_ELAPSED=$(awk '/^....-..-.. ..:..:.. real\t[0-9]/ {print $4}' < "$FASTTEST_OUTPUT/build_log.txt") + echo "build_clickhouse_fasttest_binary: [ OK ] $BUILD_SECONDS_ELAPSED sec." \ + | ts '%Y-%m-%d %H:%M:%S' \ + | tee "$FASTTEST_OUTPUT/test_result.txt" if [ "$COPY_CLICKHOUSE_BINARY_TO_OUTPUT" -eq "1" ]; then cp programs/clickhouse "$FASTTEST_OUTPUT/clickhouse" @@ -251,7 +256,7 @@ function run_tests ) time clickhouse-test "${test_opts[@]}" -- "$FASTTEST_FOCUS" 2>&1 \ | ts '%Y-%m-%d %H:%M:%S' \ - | tee "$FASTTEST_OUTPUT/test_result.txt" + | tee -a "$FASTTEST_OUTPUT/test_result.txt" set -e clickhouse stop --pid-path "$FASTTEST_DATA" diff --git a/tests/ci/fast_test_check.py b/tests/ci/fast_test_check.py index 54367f70b3f..f13b4099657 100644 --- a/tests/ci/fast_test_check.py +++ b/tests/ci/fast_test_check.py @@ -112,6 +112,9 @@ def main(): rerun_helper = RerunHelper(gh, pr_info, NAME) if rerun_helper.is_already_finished_by_status(): logging.info("Check is already finished according to github status, exiting") + status = rerun_helper.get_finished_status() + if status is not None and status.state != "success": + sys.exit(1) sys.exit(0) docker_image = get_image_with_version(temp_path, "clickhouse/fasttest")