diff --git a/.config/nextest.toml b/.config/nextest.toml index 39416445b0c..a83c5cc1e51 100644 --- a/.config/nextest.toml +++ b/.config/nextest.toml @@ -3,7 +3,7 @@ # # The required version should be bumped up if we need new features, performance # improvements or bugfixes that are present in newer versions of nextest. -nextest-version = { required = "0.9.117", recommended = "0.9.125" } +nextest-version = { required = "0.9.131", recommended = "0.9.131" } experimental = ["benchmarks", "setup-scripts"] @@ -17,9 +17,14 @@ setup = 'crdb-seed' [profile.ci] fail-fast = false +retries = 2 +flaky-result = "fail" [profile.ci.junit] path = "junit.xml" +# Mark flaky-fail tests as passing in JUnit output since we care about that +# output for analysis, not visualization. +flaky-fail-status = "success" [scripts.setup.crdb-seed] # Use the test profile for this executable since that's how almost all diff --git a/.github/buildomat/build-and-test.sh b/.github/buildomat/build-and-test.sh index 4ad2e5c4a03..26098ebdda0 100755 --- a/.github/buildomat/build-and-test.sh +++ b/.github/buildomat/build-and-test.sh @@ -18,7 +18,7 @@ target_os=$1 # NOTE: This version should be in sync with the recommended version in # .config/nextest.toml. (Maybe build an automated way to pull the recommended # version in the future.) -NEXTEST_VERSION='0.9.125' +NEXTEST_VERSION='0.9.131' cargo --version rustc --version @@ -138,6 +138,7 @@ RECORDING_CONFIG_DIR="/tmp/nextest-recording-config" RECORDING_CONFIG="$RECORDING_CONFIG_DIR/config.toml" NEXTEST_STATE_DIR="$(mktemp -d /tmp/nextest-state.XXXXXX)" ARCHIVE_PATH="/tmp/nextest-run-archive.zip" +CHROME_TRACE_PATH="/tmp/nextest-chrome-trace.json" mkdir -p "$RECORDING_CONFIG_DIR" printf '[experimental]\nrecord = true\n\n[record]\nenabled = true\n' \ @@ -160,6 +161,12 @@ if ! ptime -m cargo nextest store export latest \ echo "warning: failed to export recording archive" >&2 fi +if ! ptime -m cargo nextest store export-chrome-trace latest \ + --user-config-file "$RECORDING_CONFIG" \ + --output "$CHROME_TRACE_PATH"; then + echo "warning: failed to export Chrome trace" >&2 +fi + if [[ "$NEXTEST_EXIT" -ne 0 ]]; then echo "error: cargo nextest run failed with exit code $NEXTEST_EXIT" >&2 exit "$NEXTEST_EXIT" diff --git a/.github/buildomat/jobs/build-and-test-helios.sh b/.github/buildomat/jobs/build-and-test-helios.sh index 0671a5b8b8c..dc665ee5a87 100755 --- a/.github/buildomat/jobs/build-and-test-helios.sh +++ b/.github/buildomat/jobs/build-and-test-helios.sh @@ -9,6 +9,7 @@ #: "%/work/oxidecomputer/omicron/target/nextest/ci/junit.xml", #: "%/work/oxidecomputer/omicron/target/live-tests-archive.tgz", #: "=/tmp/nextest-run-archive.zip", +#: "=/tmp/nextest-chrome-trace.json", #: "%/var/tmp/omicron_tmp/**/*", #: "!/var/tmp/omicron_tmp/crdb-base*", #: "!/var/tmp/omicron_tmp/rustc*", @@ -41,5 +42,10 @@ #: series = "nextest-recording-helios" #: name = "nextest-run-archive.zip" #: from_output = "/tmp/nextest-run-archive.zip" +#: +#: [[publish]] +#: series = "nextest-recording-helios" +#: name = "nextest-chrome-trace.json" +#: from_output = "/tmp/nextest-chrome-trace.json" exec .github/buildomat/build-and-test.sh illumos diff --git a/.github/buildomat/jobs/build-and-test-linux.sh b/.github/buildomat/jobs/build-and-test-linux.sh index a9eed80a686..9cefedbd212 100755 --- a/.github/buildomat/jobs/build-and-test-linux.sh +++ b/.github/buildomat/jobs/build-and-test-linux.sh @@ -8,6 +8,7 @@ #: "%/work/*", #: "%/work/oxidecomputer/omicron/target/nextest/ci/junit.xml", #: "=/tmp/nextest-run-archive.zip", +#: "=/tmp/nextest-chrome-trace.json", #: "%/var/tmp/omicron_tmp/**/*", #: "!/var/tmp/omicron_tmp/crdb-base*", #: "!/var/tmp/omicron_tmp/rustc*", @@ -35,7 +36,11 @@ #: series = "nextest-recording-linux" #: name = "nextest-run-archive.zip" #: from_output = "/tmp/nextest-run-archive.zip" - +#: +#: [[publish]] +#: series = "nextest-recording-linux" +#: name = "nextest-chrome-trace.json" +#: from_output = "/tmp/nextest-chrome-trace.json" sudo apt-get install -y jq exec .github/buildomat/build-and-test.sh linux