From f2fd5707f098788385e2734ec6a9973ad7ca0e44 Mon Sep 17 00:00:00 2001 From: Piotr Siuszko Date: Sat, 21 Jun 2025 21:50:23 +0200 Subject: [PATCH] Clean up JSON schema test messages --- crates/bevy_remote/src/schemas/json_schema.rs | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/crates/bevy_remote/src/schemas/json_schema.rs b/crates/bevy_remote/src/schemas/json_schema.rs index 22d3eaa880..e6527d9585 100644 --- a/crates/bevy_remote/src/schemas/json_schema.rs +++ b/crates/bevy_remote/src/schemas/json_schema.rs @@ -418,6 +418,10 @@ mod tests { else { panic!("Failed to export JSON schema for Foo"); }; + eprintln!( + "{}", + serde_json::to_string_pretty(&schema).expect("Failed to serialize schema") + ); schema } @@ -432,7 +436,6 @@ mod tests { } let schema = export_type::(); - eprintln!("{}", serde_json::to_string_pretty(&schema).expect("msg")); assert!( !schema.reflect_types.contains(&"Component".to_owned()), "Should not be a component" @@ -463,7 +466,6 @@ mod tests { NoValue, } let schema = export_type::(); - eprintln!("{}", serde_json::to_string_pretty(&schema).expect("msg")); assert!( schema.reflect_types.contains(&"Component".to_owned()), "Should be a component" @@ -533,7 +535,7 @@ mod tests { let type_registry = atr.read(); let schema = type_registry .export_type_json_schema::(&metadata) - .expect("Failed to export"); + .expect("Failed to export schema"); assert!( !metadata.has_type_data::(&schema.reflect_types), "Should not be a component" @@ -582,7 +584,7 @@ mod tests { let type_registry = atr.read(); let schema = type_registry .export_type_json_schema::(&SchemaTypesMetadata::default()) - .expect("Failed to export"); + .expect("Failed to export schema"); assert!( !schema.reflect_types.contains(&"Component".to_owned()), "Should not be a component" @@ -625,8 +627,7 @@ mod tests { } let schema = export_type::(); - let schema_as_value = serde_json::to_value(&schema).expect("Should serialize"); - eprintln!("{:#?}", &schema_as_value); + let schema_as_value = serde_json::to_value(&schema).expect("Failed to serialize schema"); let value = json!({ "shortPath": "Foo", "$schema": "https://json-schema.org/draft/2020-12/schema", @@ -652,7 +653,6 @@ mod tests { "description": "Test doc", "shortPath": "u16", "typePath": "u16", - }, }, "required": [