mirror of
https://github.com/flatcar/scripts.git
synced 2025-08-06 20:47:00 +02:00
This change adds markdown output support to tapfile helper. tap_generate_report() has been refactored to use low-level output functions to write tests; TAP and markdown output is supported and both are generated by default. Also, it should be straightforward to add other output formats by implementing the respective low level print functions. The markdown output is now used by run-kola-tests.yaml to generate step output and, if run from a PR, add a comment with test results to the PR. Signed-off-by: Thilo Fromm <thilofromm@microsoft.com>
31 lines
898 B
Bash
Executable File
31 lines
898 B
Bash
Executable File
#!/bin/bash
|
|
#
|
|
# Copyright (c) 2021 The Flatcar Maintainers.
|
|
# Use of this source code is governed by a BSD-style license that can be
|
|
# found in the LICENSE file.
|
|
|
|
# Helper script for test.sh to update the test failures text file.
|
|
# test.sh uses this to determine which tests need to re-run.
|
|
# This script is run within the SDK container.
|
|
|
|
set -euo pipefail
|
|
|
|
arch="$1"
|
|
vernum="$2"
|
|
image="$3"
|
|
retry="$4"
|
|
tapfile="$5"
|
|
failfile="$6"
|
|
merged_summary="$7"
|
|
merged_detailed="$8"
|
|
|
|
source ci-automation/ci-config.env
|
|
source ci-automation/tapfile_helper_lib.sh
|
|
tap_ingest_tapfile "${tapfile}" "${image}" "${retry}"
|
|
tap_failed_tests_for_vendor "${image}" > "${failfile}"
|
|
|
|
for format in "${TEST_REPORT_FORMATS[@]}"; do
|
|
tap_generate_report "${arch}" "${vernum}" "${format}" > "${merged_summary}.${format}"
|
|
tap_generate_report "${arch}" "${vernum}" "${format}" "true" > "${merged_detailed}.${format}"
|
|
done
|