@@ -219,7 +219,7 @@ async fn test_processed_to_device_variants() {
219
219
220
220
insta:: with_settings!( { prepend_module_to_snapshot => false } , {
221
221
assert_json_snapshot!(
222
- serde_json :: from_str :: < Value > ( processed_event. to_raw( ) . json ( ) . get ( ) ) . unwrap( ) ,
222
+ processed_event. to_raw( ) . deserialize_as :: < Value > ( ) . unwrap( ) ,
223
223
{
224
224
".keys.ed25519" => "[sender_ed25519_key]" ,
225
225
r#"["org.matrix.msc4147.device_keys"].device_id"# => "[ABCDEFGH]" ,
@@ -237,7 +237,7 @@ async fn test_processed_to_device_variants() {
237
237
238
238
insta:: with_settings!( { prepend_module_to_snapshot => false } , {
239
239
assert_json_snapshot!(
240
- serde_json :: from_str :: < Value > ( processed_event. to_raw( ) . json ( ) . get ( ) ) . unwrap( ) ,
240
+ processed_event. to_raw( ) . deserialize_as :: < Value > ( ) . unwrap( ) ,
241
241
) ;
242
242
} ) ;
243
243
@@ -246,7 +246,7 @@ async fn test_processed_to_device_variants() {
246
246
247
247
insta:: with_settings!( { prepend_module_to_snapshot => false } , {
248
248
assert_json_snapshot!(
249
- serde_json :: from_str :: < Value > ( processed_event. to_raw( ) . json ( ) . get ( ) ) . unwrap( ) ,
249
+ processed_event. to_raw( ) . deserialize_as :: < Value > ( ) . unwrap( ) ,
250
250
) ;
251
251
} ) ;
252
252
@@ -255,7 +255,7 @@ async fn test_processed_to_device_variants() {
255
255
256
256
insta:: with_settings!( { prepend_module_to_snapshot => false } , {
257
257
assert_json_snapshot!(
258
- serde_json :: from_str :: < Value > ( processed_event. to_raw( ) . json ( ) . get ( ) ) . unwrap( ) ,
258
+ processed_event. to_raw( ) . deserialize_as :: < Value > ( ) . unwrap( ) ,
259
259
{
260
260
".content.sender_key" => "[sender_ed25519_key]" ,
261
261
".content.ciphertext" => "[++REDACTED++]" ,
0 commit comments