Index: schemars/tests/integration/test_helper.rs =================================================================== --- schemars.orig/tests/integration/test_helper.rs +++ schemars/tests/integration/test_helper.rs @@ -71,9 +71,10 @@ impl TestHelper { /// /// Run tests with the SNAPSHOTS env var set to "overwrite" to overwrite any changed snapshots. pub fn assert_snapshot(&self) -> &Self { - let common_path = format!("tests/integration/snapshots/{}.json", self.name); - let de_path = format!("tests/integration/snapshots/{}.de.json", self.name); - let ser_path = format!("tests/integration/snapshots/{}.ser.json", self.name); + let stripped_name = self.name.strip_prefix("schemars/").unwrap_or(&self.name); + let common_path = format!("tests/integration/snapshots/schemars/{}.json", stripped_name); + let de_path = format!("tests/integration/snapshots/schemars/{}.de.json", stripped_name); + let ser_path = format!("tests/integration/snapshots/schemars/{}.ser.json", stripped_name); if self.de_schema == self.ser_schema { snapbox::assert_data_eq!(