From f9447f7360e699e0fcc1bcc0c5a9b261838ce4e5 Mon Sep 17 00:00:00 2001 From: a2x <45197573+a2x@users.noreply.github.com> Date: Thu, 15 Aug 2024 11:31:17 +1000 Subject: [PATCH] Fix tests --- src/analysis/offsets.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/analysis/offsets.rs b/src/analysis/offsets.rs index d85cdf0..e82468b 100644 --- a/src/analysis/offsets.rs +++ b/src/analysis/offsets.rs @@ -173,7 +173,9 @@ mod tests { } fn get_class_field_value(module_name: &str, class_name: &str, field_name: &str) -> Option { - let content = fs::read_to_string(format!("output/{}.json", module_name)).ok()?; + let content = + fs::read_to_string(format!("output/{}.json", module_name.replace(".", "_"))).ok()?; + let value: Value = serde_json::from_str(&content).ok()?; value