11#[ cfg( test) ]
22mod error_record_integration_tests {
33 use crate :: ps_value:: {
4- ComplexObject , ComplexObjectContent , PsPrimitiveValue , PsProperty , PsType , PsValue ,
4+ ComplexObject , ComplexObjectContent , PsPrimitiveValue , PsProperty , PsValue ,
55 } ;
66 use crate :: { ErrorCategory , ErrorRecord } ;
77 use std:: collections:: BTreeMap ;
@@ -26,9 +26,8 @@ mod error_record_integration_tests {
2626 . expect ( "Should successfully deserialize XML to PsValue" ) ;
2727
2828 // Extract the ComplexObject from PsValue
29- let complex_object = match ps_value {
30- PsValue :: Object ( obj) => obj,
31- _ => panic ! ( "Expected PsValue::Object from XML parsing" ) ,
29+ let PsValue :: Object ( complex_object) = ps_value else {
30+ panic ! ( "Expected PsValue::Object from XML parsing" )
3231 } ;
3332
3433 println ! ( "✅ Successfully parsed XML into ComplexObject" ) ;
@@ -86,7 +85,7 @@ mod error_record_integration_tests {
8685 ) ;
8786 }
8887 Err ( e) => {
89- panic ! ( "❌ Failed to parse ErrorRecord: {}" , e ) ;
88+ panic ! ( "❌ Failed to parse ErrorRecord: {e}" ) ;
9089 }
9190 }
9291 }
@@ -192,7 +191,7 @@ mod error_record_integration_tests {
192191 . serialize_extended_info ( false )
193192 . error_category ( Some ( ErrorCategory :: builder ( )
194193 . category ( 13 )
195- . activity ( Some ( "" . to_string ( ) ) )
194+ . activity ( Some ( String :: new ( ) ) )
196195 . reason ( Some ( "CommandNotFoundException" . to_string ( ) ) )
197196 . target_name ( Some ( "ed" . to_string ( ) ) )
198197 . target_type ( Some ( "String" . to_string ( ) ) )
0 commit comments