Skip to content

Commit 4a697ab

Browse files
randyquayeclaude
andcommitted
fix(arbtest): use --manifest-path so cargo finds workspace from /output
cargo test was running from $FUZZ_OUTPUT_DIR (/output) where there is no Cargo.toml. Without --manifest-path, cargo fails with "could not find Cargo.toml". Also removed unnecessary cd to /output since cargo test doesn't write to CWD. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent b6692a3 commit 4a697ab

1 file changed

Lines changed: 2 additions & 5 deletions

File tree

tooling/ast_fuzzer/arbtest-container/entrypoint.sh

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -113,9 +113,8 @@ if [ "$FUZZ_MODE" = "reproduce" ]; then
113113
# Full backtrace in reproduce mode — useful for debugging the specific crash.
114114
export RUST_BACKTRACE=1
115115

116-
cd "$FUZZ_OUTPUT_DIR"
117116
set +e
118-
cargo test --release -p noir_ast_fuzzer_fuzz "$FUZZ_TARGET" 2>&1 | tee "$FUZZ_OUTPUT_DIR/reproduce.log"
117+
cargo test --release --manifest-path /noir/Cargo.toml -p noir_ast_fuzzer_fuzz "$FUZZ_TARGET" 2>&1 | tee "$FUZZ_OUTPUT_DIR/reproduce.log"
119118
EXIT_CODE=${PIPESTATUS[0]}
120119
set -e
121120

@@ -143,8 +142,6 @@ export NOIR_AST_FUZZER_BUDGET_SECS="$ARBTEST_BUDGET"
143142
# Minimum stack size for deep AST recursion.
144143
export RUST_MIN_STACK="${RUST_MIN_STACK:-8388608}"
145144

146-
cd "$FUZZ_OUTPUT_DIR"
147-
148145
START_TIME=$(date +%s)
149146
ITERATION=0
150147
CRASH_FOUND=0
@@ -175,7 +172,7 @@ while true; do
175172
LOG_FILE=$(mktemp "$FUZZ_OUTPUT_DIR/iter-${ITERATION}-XXXXXX.log")
176173

177174
set +e
178-
cargo test --release -p noir_ast_fuzzer_fuzz "$FUZZ_TARGET" 2>&1 | tee "$LOG_FILE"
175+
cargo test --release --manifest-path /noir/Cargo.toml -p noir_ast_fuzzer_fuzz "$FUZZ_TARGET" 2>&1 | tee "$LOG_FILE"
179176
EXIT_CODE=${PIPESTATUS[0]}
180177
set -e
181178

0 commit comments

Comments
 (0)