@@ -74,17 +74,9 @@ public function testSymfonySerialize()
74
74
"html": null,
75
75
"htmlCharset": null,
76
76
"attachments": [
77
- {
78
- "filename": "test.txt",
79
- "mediaType": "application",
80
- "body": "Some Text file",
81
- "charset": null,
82
- "subtype": "octet-stream",
83
- "disposition": "attachment",
84
- "name": "test.txt",
85
- "encoding": "base64",
86
- "headers": [],
87
- "class": "Symfony\\\Component\\\Mime\\\Part\\\DataPart"
77
+ {%A
78
+ "body": "Some Text file",%A
79
+ "name": "test.txt",%A
88
80
}
89
81
],
90
82
"headers": {
@@ -118,11 +110,11 @@ public function testSymfonySerialize()
118
110
], [new JsonEncoder ()]);
119
111
120
112
$ serialized = $ serializer ->serialize ($ e , 'json ' , [ObjectNormalizer::IGNORED_ATTRIBUTES => ['cachedBody ' ]]);
121
- $ this ->assertSame ($ expectedJson , json_encode (json_decode ($ serialized ), \JSON_PRETTY_PRINT | \JSON_UNESCAPED_SLASHES ));
113
+ $ this ->assertStringMatchesFormat ($ expectedJson , json_encode (json_decode ($ serialized ), \JSON_PRETTY_PRINT | \JSON_UNESCAPED_SLASHES ));
122
114
123
115
$ n = $ serializer ->deserialize ($ serialized , TemplatedEmail::class, 'json ' );
124
116
$ serialized = $ serializer ->serialize ($ e , 'json ' , [ObjectNormalizer::IGNORED_ATTRIBUTES => ['cachedBody ' ]]);
125
- $ this ->assertSame ($ expectedJson , json_encode (json_decode ($ serialized ), \JSON_PRETTY_PRINT | \JSON_UNESCAPED_SLASHES ));
117
+ $ this ->assertStringMatchesFormat ($ expectedJson , json_encode (json_decode ($ serialized ), \JSON_PRETTY_PRINT | \JSON_UNESCAPED_SLASHES ));
126
118
127
119
128
120
$ expected->
from (
'[email protected] ' );
0 commit comments