diff --git a/crates/oapi/src/openapi/schema/all_of.rs b/crates/oapi/src/openapi/schema/all_of.rs index 4d944feae..25886fb97 100644 --- a/crates/oapi/src/openapi/schema/all_of.rs +++ b/crates/oapi/src/openapi/schema/all_of.rs @@ -226,9 +226,9 @@ mod tests { #[test] fn test_allof_with_extensions() { let expected = json!("value"); - let json_value = AllOf::new().extensions(Some( + let json_value = AllOf::new().extensions( [("x-some-extension".to_string(), expected.clone())].into(), - )); + ); let value = serde_json::to_value(&json_value).unwrap(); assert_eq!(value.get("x-some-extension"), Some(&expected)); diff --git a/crates/oapi/src/openapi/schema/any_of.rs b/crates/oapi/src/openapi/schema/any_of.rs index 745b67c78..e1307401d 100644 --- a/crates/oapi/src/openapi/schema/any_of.rs +++ b/crates/oapi/src/openapi/schema/any_of.rs @@ -226,9 +226,9 @@ mod tests { #[test] fn test_anyof_with_extensions() { let expected = json!("value"); - let json_value = AnyOf::new().extensions(Some( + let json_value = AnyOf::new().extensions( [("x-some-extension".to_string(), expected.clone())].into(), - )); + ); let value = serde_json::to_value(&json_value).unwrap(); assert_eq!(value.get("x-some-extension"), Some(&expected)); diff --git a/crates/oapi/src/openapi/schema/array.rs b/crates/oapi/src/openapi/schema/array.rs index d9389f2cb..a6969848a 100644 --- a/crates/oapi/src/openapi/schema/array.rs +++ b/crates/oapi/src/openapi/schema/array.rs @@ -271,9 +271,9 @@ mod tests { #[test] fn test_array_with_extensions() { let expected = json!("value"); - let json_value = Array::default().extensions(Some( + let json_value = Array::default().extensions( [("x-some-extension".to_string(), expected.clone())].into(), - )); + ); let value = serde_json::to_value(&json_value).unwrap(); assert_eq!(value.get("x-some-extension"), Some(&expected)); diff --git a/crates/oapi/src/openapi/schema/object.rs b/crates/oapi/src/openapi/schema/object.rs index 96f327292..bafa5a479 100644 --- a/crates/oapi/src/openapi/schema/object.rs +++ b/crates/oapi/src/openapi/schema/object.rs @@ -472,9 +472,9 @@ mod tests { #[test] fn test_object_with_extensions() { let expected = json!("value"); - let json_value = Object::new().extensions(Some( + let json_value = Object::new().extensions( [("x-some-extension".to_string(), expected.clone())].into(), - )); + ); let value = serde_json::to_value(&json_value).unwrap(); assert_eq!(value.get("x-some-extension"), Some(&expected)); diff --git a/crates/oapi/src/openapi/schema/one_of.rs b/crates/oapi/src/openapi/schema/one_of.rs index 6b45520ed..f6eabbd20 100644 --- a/crates/oapi/src/openapi/schema/one_of.rs +++ b/crates/oapi/src/openapi/schema/one_of.rs @@ -226,9 +226,9 @@ mod tests { #[test] fn test_oneof_with_extensions() { let expected = json!("value"); - let json_value = OneOf::new().extensions(Some( + let json_value = OneOf::new().extensions( [("x-some-extension".to_string(), expected.clone())].into(), - )); + ); let value = serde_json::to_value(&json_value).unwrap(); assert_eq!(value.get("x-some-extension"), Some(&expected));