Skip to content

Commit

Permalink
While I'm here, make actionlint happy
Browse files Browse the repository at this point in the history
  • Loading branch information
larseggert committed Mar 11, 2024
1 parent 8bfde5c commit e34558d
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 19 deletions.
16 changes: 8 additions & 8 deletions .github/workflows/bench.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@ jobs:

- name: Build
run: |
cargo +$TOOLCHAIN bench --features bench --no-run
cargo +$TOOLCHAIN build --release --bin neqo-client --bin neqo-server
cargo "+$TOOLCHAIN" bench --features bench --no-run
cargo "+$TOOLCHAIN" build --release --bin neqo-client --bin neqo-server
- name: Download cached main-branch results
id: criterion-cache
Expand All @@ -61,7 +61,7 @@ jobs:
- name: Run cargo bench
run: |
taskset -c 0 nice -n -20 \
cargo +$TOOLCHAIN bench --features bench | tee results.txt
cargo "+$TOOLCHAIN" bench --features bench | tee results.txt
# Pin the transfer benchmark to core 0 and run it at elevated priority inside perf.
# Work around https://github.com/flamegraph-rs/flamegraph/issues/248 by passing explicit perf arguments.
Expand All @@ -72,7 +72,7 @@ jobs:
mv target/criterion target/criterion-bench
mv target/criterion-transfer-profile target/criterion || true
taskset -c 0 nice -n -20 \
cargo +$TOOLCHAIN flamegraph -v -c "$PERF_CMD" --features bench --bench transfer -- \
cargo "+$TOOLCHAIN" flamegraph -v -c "$PERF_CMD" --features bench --bench transfer -- \
--bench --exact "Run multiple transfers with varying seeds"
# And now restore the directories.
mv target/criterion target/criterion-transfer-profile
Expand All @@ -83,13 +83,13 @@ jobs:
{ mkdir server; \
cd server; \
taskset -c 0 nice -n -20 \
cargo +$TOOLCHAIN flamegraph -v -c "$PERF_CMD" \
--bin neqo-server -- --db ../test-fixture/db $HOST:4433 || true; } &
cargo "+$TOOLCHAIN" flamegraph -v -c "$PERF_CMD" \
--bin neqo-server -- --db ../test-fixture/db "$HOST:4433" || true; } &
mkdir client; \
cd client; \
time taskset -c 1 nice -n -20 \
cargo +$TOOLCHAIN flamegraph -v -c "$PERF_CMD" \
--bin neqo-client -- --output-dir . https://$HOST:4433/$SIZE
cargo "+$TOOLCHAIN" flamegraph -v -c "$PERF_CMD" \
--bin neqo-client -- --output-dir . "https://$HOST:4433/$SIZE"
killall -INT neqo-server
cd ${{ github.workspace }}
[ "$(wc -c < client/"$SIZE")" -eq "$SIZE" ] || exit 1
Expand Down
24 changes: 13 additions & 11 deletions .github/workflows/check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,8 @@ jobs:
- name: Use MSYS2 environment and install more dependencies (Windows)
if: runner.os == 'Windows'
run: |
echo "C:\\msys64\\usr\\bin" >> "$GITHUB_PATH"
echo "C:\\msys64\\mingw64\\bin" >> "$GITHUB_PATH"
printf "C:\msys64\usr\bin" >> "$GITHUB_PATH"
printf "C:\msys64\mingw64\bin" >> "$GITHUB_PATH"
/c/msys64/usr/bin/pacman -S --noconfirm nsinstall
python3 -m pip install git+https://github.com/nodejs/gyp-next
echo "$(python3 -m site --user-base)/bin" >> "$GITHUB_PATH"
Expand All @@ -85,9 +85,11 @@ jobs:
- name: Set up NSS/NSPR build environment (Windows)
if: runner.os == 'Windows'
run: |
echo "GYP_MSVS_OVERRIDE_PATH=$VSINSTALLDIR" >> "$GITHUB_ENV"
echo "GYP_MSVS_VERSION=2022" >> "$GITHUB_ENV"
echo "BASH=$SHELL" >> "$GITHUB_ENV"
{
echo "GYP_MSVS_OVERRIDE_PATH=$VSINSTALLDIR"
echo "GYP_MSVS_VERSION=2022"
echo "BASH=$SHELL"
} >> "$GITHUB_ENV"
# See https://github.com/ilammy/msvc-dev-cmd#name-conflicts-with-shell-bash
rm /usr/bin/link.exe
Expand All @@ -101,19 +103,19 @@ jobs:
uses: ./.github/actions/nss

- name: Build
run: cargo +${{ matrix.rust-toolchain }} build $BUILD_TYPE --all-targets --features ci
run: cargo +${{ matrix.rust-toolchain }} build "$BUILD_TYPE" --all-targets --features ci

- name: Run tests and determine coverage
run: |
cargo +${{ matrix.rust-toolchain }} llvm-cov nextest $BUILD_TYPE --all-targets --features ci --no-fail-fast --lcov --output-path lcov.info
cargo +${{ matrix.rust-toolchain }} llvm-cov nextest "$BUILD_TYPE" --all-targets --features ci --no-fail-fast --lcov --output-path lcov.info
cargo +${{ matrix.rust-toolchain }} bench --features bench --no-run
- name: Run client/server transfer
run: |
cargo +${{ matrix.rust-toolchain }} build $BUILD_TYPE --bin neqo-client --bin neqo-server
target/$BUILD_DIR/neqo-server $HOST:4433 &
cargo +${{ matrix.rust-toolchain }} build "$BUILD_TYPE" --bin neqo-client --bin neqo-server
"target/$BUILD_DIR/neqo-server" "$HOST:4433" &
PID=$!
target/$BUILD_DIR/neqo-client --output-dir . https://$HOST:4433/$SIZE
"target/$BUILD_DIR/neqo-client" --output-dir . "https://$HOST:4433/$SIZE"
kill $PID
[ "$(wc -c <"$SIZE")" -eq "$SIZE" ] || exit 1
env:
Expand All @@ -127,7 +129,7 @@ jobs:
if [ "${{ matrix.rust-toolchain }}" != "nightly" ]; then
CONFIG_PATH="--config-path=$(mktemp)"
fi
cargo +${{ matrix.rust-toolchain }} fmt --all -- --check $CONFIG_PATH
cargo +${{ matrix.rust-toolchain }} fmt --all -- --check "$CONFIG_PATH"
if: success() || failure()

- name: Clippy
Expand Down

0 comments on commit e34558d

Please sign in to comment.