test: fix the stale default disc paths -- three tests could never run unaided
texture_disc.rs and mesh_disc.rs fall back to "/home/fabi/RE Project Sylpheed/..." when SYLPHEED_ISO / SYLPHEED_RES3D are unset. The directory is "RE - Project Sylpheed"; the fallbacks were missing the " - ", so stage_models_decode, stage_models_sweep and stage_models_quality_audit failed with NotFound for anyone who did not happen to know the env var. They now pass unaided (10/10 in mesh_disc). Found while auditing what the suite actually exercises after withdrawing the anchor change: an ISO-gated test skipping, and an ignored test failing on a typo, are both "green" in a normal run. Full state, with SYLPHEED_ISO/DISC/RES3D set and --include-ignored: 82 lib tests and every disc/ISO suite pass; the single failure is shared_resources_decode_identically_in_every_container, which is deliberately written as the target state and #[ignore]d. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -16,7 +16,7 @@
|
|||||||
//! Usage:
|
//! Usage:
|
||||||
//! SYLPHEED_ISO=... cargo run --release --example correlate_capture -- \
|
//! SYLPHEED_ISO=... cargo run --release --example correlate_capture -- \
|
||||||
//! <capture.log> <Stage_SNN> <ship_id> [ref_part_substr] [--emit]
|
//! <capture.log> <Stage_SNN> <ship_id> [ref_part_substr] [--emit]
|
||||||
//! e.g. SYLPHEED_ISO="/home/fabi/RE Project Sylpheed/Project Sylpheed - Arc of
|
//! e.g. SYLPHEED_ISO="/home/fabi/RE - Project Sylpheed/Project Sylpheed - Arc of
|
||||||
//! Deception (USA, Europe) (En,Ja).iso" \
|
//! Deception (USA, Europe) (En,Ja).iso" \
|
||||||
//! cargo run --release --example correlate_capture -- \
|
//! cargo run --release --example correlate_capture -- \
|
||||||
//! xenia_ship_capture.log Stage_S01 e106 bdy_04 --emit
|
//! xenia_ship_capture.log Stage_S01 e106 bdy_04 --emit
|
||||||
|
|||||||
@@ -17,7 +17,7 @@ fn res3d_dir() -> Option<PathBuf> {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
let default =
|
let default =
|
||||||
PathBuf::from("/home/fabi/RE Project Sylpheed/sylph_extract/hidden/resource3d");
|
PathBuf::from("/home/fabi/RE - Project Sylpheed/sylph_extract/hidden/resource3d");
|
||||||
default.is_dir().then_some(default)
|
default.is_dir().then_some(default)
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -321,7 +321,7 @@ fn hero_ship_grouped_pool_decodes() {
|
|||||||
fn stage_models_decode() {
|
fn stage_models_decode() {
|
||||||
use sylpheed_formats::mesh::Xbg7Model;
|
use sylpheed_formats::mesh::Xbg7Model;
|
||||||
let dir = std::env::var("SYLPHEED_RES3D").unwrap_or_else(|_| {
|
let dir = std::env::var("SYLPHEED_RES3D").unwrap_or_else(|_| {
|
||||||
"/home/fabi/RE Project Sylpheed/sylph_extract/hidden/resource3d".to_string()
|
"/home/fabi/RE - Project Sylpheed/sylph_extract/hidden/resource3d".to_string()
|
||||||
});
|
});
|
||||||
let path = format!("{dir}/Stage_S10.xpr");
|
let path = format!("{dir}/Stage_S10.xpr");
|
||||||
let bytes = std::fs::read(&path).expect("read Stage_S10");
|
let bytes = std::fs::read(&path).expect("read Stage_S10");
|
||||||
@@ -359,7 +359,7 @@ fn stage_models_sweep() {
|
|||||||
use sylpheed_formats::mesh::Xbg7Model;
|
use sylpheed_formats::mesh::Xbg7Model;
|
||||||
use std::time::Instant;
|
use std::time::Instant;
|
||||||
let dir = std::env::var("SYLPHEED_RES3D").unwrap_or_else(|_| {
|
let dir = std::env::var("SYLPHEED_RES3D").unwrap_or_else(|_| {
|
||||||
"/home/fabi/RE Project Sylpheed/sylph_extract/hidden/resource3d".to_string()
|
"/home/fabi/RE - Project Sylpheed/sylph_extract/hidden/resource3d".to_string()
|
||||||
});
|
});
|
||||||
let mut names: Vec<_> = std::fs::read_dir(&dir)
|
let mut names: Vec<_> = std::fs::read_dir(&dir)
|
||||||
.unwrap()
|
.unwrap()
|
||||||
@@ -386,7 +386,7 @@ fn stage_models_sweep() {
|
|||||||
fn stage_models_quality_audit() {
|
fn stage_models_quality_audit() {
|
||||||
use sylpheed_formats::mesh::Xbg7Model;
|
use sylpheed_formats::mesh::Xbg7Model;
|
||||||
let dir = std::env::var("SYLPHEED_RES3D").unwrap_or_else(|_| {
|
let dir = std::env::var("SYLPHEED_RES3D").unwrap_or_else(|_| {
|
||||||
"/home/fabi/RE Project Sylpheed/sylph_extract/hidden/resource3d".to_string()
|
"/home/fabi/RE - Project Sylpheed/sylph_extract/hidden/resource3d".to_string()
|
||||||
});
|
});
|
||||||
let bytes = std::fs::read(format!("{dir}/Stage_S07.xpr")).unwrap();
|
let bytes = std::fs::read(format!("{dir}/Stage_S07.xpr")).unwrap();
|
||||||
let models = Xbg7Model::stage_models(&bytes);
|
let models = Xbg7Model::stage_models(&bytes);
|
||||||
|
|||||||
@@ -19,7 +19,7 @@ fn iso_path() -> Option<PathBuf> {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
let default = PathBuf::from(
|
let default = PathBuf::from(
|
||||||
"/home/fabi/RE Project Sylpheed/Project Sylpheed - Arc of Deception (USA, Europe) (En,Ja).iso",
|
"/home/fabi/RE - Project Sylpheed/Project Sylpheed - Arc of Deception (USA, Europe) (En,Ja).iso",
|
||||||
);
|
);
|
||||||
default.is_file().then_some(default)
|
default.is_file().then_some(default)
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user