fix: update run_tests tests for Stdio::inherit and bump tool count to 60

run_tests now uses Stdio::inherit so stdout/stderr aren't captured —
tests can only assert on pass/fail and exit code. Tool count bumped
from 59 to 60 for the new get_test_result tool.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
dave
2026-04-12 12:30:10 +00:00
parent 05bdc71ebc
commit f140238cc3
2 changed files with 3 additions and 8 deletions
+2 -7
View File
@@ -966,7 +966,7 @@ mod tests {
let script_dir = tmp.path().join("script");
std::fs::create_dir_all(&script_dir).unwrap();
let script_path = script_dir.join("test");
std::fs::write(&script_path, "#!/usr/bin/env bash\necho 'test result: ok. 3 passed; 0 failed'\nexit 0\n").unwrap();
std::fs::write(&script_path, "#!/usr/bin/env bash\nexit 0\n").unwrap();
#[cfg(unix)]
{
use std::os::unix::fs::PermissionsExt;
@@ -979,9 +979,6 @@ mod tests {
assert_eq!(parsed["passed"], true);
assert_eq!(parsed["exit_code"], 0);
assert_eq!(parsed["timed_out"], false);
assert_eq!(parsed["tests_passed"], 3);
assert_eq!(parsed["tests_failed"], 0);
}
#[tokio::test]
@@ -990,7 +987,7 @@ mod tests {
let script_dir = tmp.path().join("script");
std::fs::create_dir_all(&script_dir).unwrap();
let script_path = script_dir.join("test");
std::fs::write(&script_path, "#!/usr/bin/env bash\necho 'test result: FAILED. 1 passed; 2 failed'\nexit 1\n").unwrap();
std::fs::write(&script_path, "#!/usr/bin/env bash\nexit 1\n").unwrap();
#[cfg(unix)]
{
use std::os::unix::fs::PermissionsExt;
@@ -1003,8 +1000,6 @@ mod tests {
assert_eq!(parsed["passed"], false);
assert_eq!(parsed["exit_code"], 1);
assert_eq!(parsed["tests_passed"], 1);
assert_eq!(parsed["tests_failed"], 2);
}
#[tokio::test]