@@ -75,7 +75,7 @@ public function testCompleteWriteProcessAddFiles()
75
75
<tool tool-id="symfony" tool-name="Symfony"/>
76
76
</header>
77
77
<body>
78
- <trans-unit id="ypeBEso " resname="a">
78
+ <trans-unit id="%s " resname="a">
79
79
<source>a</source>
80
80
<target>trans_en_a</target>
81
81
</trans-unit>
@@ -93,7 +93,7 @@ public function testCompleteWriteProcessAddFiles()
93
93
<tool tool-id="symfony" tool-name="Symfony"/>
94
94
</header>
95
95
<body>
96
- <trans-unit id="is7pld7 " resname="post.num_comments">
96
+ <trans-unit id="%s " resname="post.num_comments">
97
97
<source>post.num_comments</source>
98
98
<target>{count, plural, one {# comment} other {# comments}}</target>
99
99
</trans-unit>
@@ -116,7 +116,7 @@ public function testCompleteWriteProcessAddFiles()
116
116
$ this ->assertSame ('https://api.crowdin.com/api/v2/storages ' , $ url );
117
117
$ this ->assertSame ('Content-Type: application/octet-stream ' , $ options ['normalized_headers ' ]['content-type ' ][0 ]);
118
118
$ this ->assertSame ('Crowdin-API-FileName: messages.xlf ' , $ options ['normalized_headers ' ]['crowdin-api-filename ' ][0 ]);
119
- $ this ->assertSame ($ expectedMessagesFileContent , $ options ['body ' ]);
119
+ $ this ->assertStringMatchesFormat ($ expectedMessagesFileContent , $ options ['body ' ]);
120
120
121
121
return new JsonMockResponse (['data ' => ['id ' => 19 ]], ['http_code ' => 201 ]);
122
122
},
@@ -132,7 +132,7 @@ public function testCompleteWriteProcessAddFiles()
132
132
$ this ->assertSame ('https://api.crowdin.com/api/v2/storages ' , $ url );
133
133
$ this ->assertSame ('Content-Type: application/octet-stream ' , $ options ['normalized_headers ' ]['content-type ' ][0 ]);
134
134
$ this ->assertSame ('Crowdin-API-FileName: validators.xlf ' , $ options ['normalized_headers ' ]['crowdin-api-filename ' ][0 ]);
135
- $ this ->assertSame ($ expectedValidatorsFileContent , $ options ['body ' ]);
135
+ $ this ->assertStringMatchesFormat ($ expectedValidatorsFileContent , $ options ['body ' ]);
136
136
137
137
return new JsonMockResponse (['data ' => ['id ' => 19 ]], ['http_code ' => 201 ]);
138
138
},
@@ -171,7 +171,7 @@ public function testWriteAddFileServerError()
171
171
<tool tool-id="symfony" tool-name="Symfony"/>
172
172
</header>
173
173
<body>
174
- <trans-unit id="ypeBEso " resname="a">
174
+ <trans-unit id="%s " resname="a">
175
175
<source>a</source>
176
176
<target>trans_en_a</target>
177
177
</trans-unit>
@@ -194,7 +194,7 @@ public function testWriteAddFileServerError()
194
194
$ this ->assertSame ('https://api.crowdin.com/api/v2/storages ' , $ url );
195
195
$ this ->assertSame ('Content-Type: application/octet-stream ' , $ options ['normalized_headers ' ]['content-type ' ][0 ]);
196
196
$ this ->assertSame ('Crowdin-API-FileName: messages.xlf ' , $ options ['normalized_headers ' ]['crowdin-api-filename ' ][0 ]);
197
- $ this ->assertSame ($ expectedMessagesFileContent , $ options ['body ' ]);
197
+ $ this ->assertStringMatchesFormat ($ expectedMessagesFileContent , $ options ['body ' ]);
198
198
199
199
return new JsonMockResponse (['data ' => ['id ' => 19 ]], ['http_code ' => 201 ]);
200
200
},
@@ -236,7 +236,7 @@ public function testWriteUpdateFileServerError()
236
236
<tool tool-id="symfony" tool-name="Symfony"/>
237
237
</header>
238
238
<body>
239
- <trans-unit id="ypeBEso " resname="a">
239
+ <trans-unit id="%s " resname="a">
240
240
<source>a</source>
241
241
<target>trans_en_a</target>
242
242
</trans-unit>
@@ -266,7 +266,7 @@ public function testWriteUpdateFileServerError()
266
266
$ this ->assertSame ('https://api.crowdin.com/api/v2/storages ' , $ url );
267
267
$ this ->assertSame ('Content-Type: application/octet-stream ' , $ options ['normalized_headers ' ]['content-type ' ][0 ]);
268
268
$ this ->assertSame ('Crowdin-API-FileName: messages.xlf ' , $ options ['normalized_headers ' ]['crowdin-api-filename ' ][0 ]);
269
- $ this ->assertSame ($ expectedMessagesFileContent , $ options ['body ' ]);
269
+ $ this ->assertStringMatchesFormat ($ expectedMessagesFileContent , $ options ['body ' ]);
270
270
271
271
return new JsonMockResponse (['data ' => ['id ' => 19 ]], ['http_code ' => 201 ]);
272
272
},
@@ -308,7 +308,7 @@ public function testWriteUploadTranslationsServerError()
308
308
<tool tool-id="symfony" tool-name="Symfony"/>
309
309
</header>
310
310
<body>
311
- <trans-unit id="ypeBEso " resname="a">
311
+ <trans-unit id="%s " resname="a">
312
312
<source>a</source>
313
313
<target>trans_fr_a</target>
314
314
</trans-unit>
@@ -326,7 +326,7 @@ public function testWriteUploadTranslationsServerError()
326
326
<tool tool-id="symfony" tool-name="Symfony"/>
327
327
</header>
328
328
<body>
329
- <trans-unit id="ypeBEso " resname="a">
329
+ <trans-unit id="%s " resname="a">
330
330
<source>a</source>
331
331
<target>trans_en_a</target>
332
332
</trans-unit>
@@ -355,7 +355,7 @@ public function testWriteUploadTranslationsServerError()
355
355
$ this ->assertSame ('https://api.crowdin.com/api/v2/storages ' , $ url );
356
356
$ this ->assertSame ('Content-Type: application/octet-stream ' , $ options ['normalized_headers ' ]['content-type ' ][0 ]);
357
357
$ this ->assertSame ('Crowdin-API-FileName: messages.xlf ' , $ options ['normalized_headers ' ]['crowdin-api-filename ' ][0 ]);
358
- $ this ->assertSame ($ expectedMessagesFileContent , $ options ['body ' ]);
358
+ $ this ->assertStringMatchesFormat ($ expectedMessagesFileContent , $ options ['body ' ]);
359
359
360
360
return new JsonMockResponse (['data ' => ['id ' => 19 ]], ['http_code ' => 201 ]);
361
361
},
@@ -371,7 +371,7 @@ public function testWriteUploadTranslationsServerError()
371
371
$ this ->assertSame ('https://api.crowdin.com/api/v2/storages ' , $ url );
372
372
$ this ->assertSame ('Content-Type: application/octet-stream ' , $ options ['normalized_headers ' ]['content-type ' ][0 ]);
373
373
$ this ->assertSame ('Crowdin-API-FileName: messages.xlf ' , $ options ['normalized_headers ' ]['crowdin-api-filename ' ][0 ]);
374
- $ this ->assertSame ($ expectedMessagesTranslationsContent , $ options ['body ' ]);
374
+ $ this ->assertStringMatchesFormat ($ expectedMessagesTranslationsContent , $ options ['body ' ]);
375
375
376
376
return new JsonMockResponse (['data ' => ['id ' => 19 ]], ['http_code ' => 201 ]);
377
377
},
@@ -415,11 +415,11 @@ public function testCompleteWriteProcessUpdateFiles()
415
415
<tool tool-id="symfony" tool-name="Symfony"/>
416
416
</header>
417
417
<body>
418
- <trans-unit id="ypeBEso " resname="a">
418
+ <trans-unit id="%s " resname="a">
419
419
<source>a</source>
420
420
<target>trans_en_a</target>
421
421
</trans-unit>
422
- <trans-unit id="PiPoFgA " resname="b">
422
+ <trans-unit id="%s " resname="b">
423
423
<source>b</source>
424
424
<target>trans_en_b</target>
425
425
</trans-unit>
@@ -448,7 +448,7 @@ public function testCompleteWriteProcessUpdateFiles()
448
448
$ this ->assertSame ('https://api.crowdin.com/api/v2/storages ' , $ url );
449
449
$ this ->assertSame ('Content-Type: application/octet-stream ' , $ options ['normalized_headers ' ]['content-type ' ][0 ]);
450
450
$ this ->assertSame ('Crowdin-API-FileName: messages.xlf ' , $ options ['normalized_headers ' ]['crowdin-api-filename ' ][0 ]);
451
- $ this ->assertSame ($ expectedMessagesFileContent , $ options ['body ' ]);
451
+ $ this ->assertStringMatchesFormat ($ expectedMessagesFileContent , $ options ['body ' ]);
452
452
453
453
return new JsonMockResponse (['data ' => ['id ' => 19 ]], ['http_code ' => 201 ]);
454
454
},
@@ -489,7 +489,7 @@ public function testCompleteWriteProcessAddFileAndUploadTranslations(TranslatorB
489
489
<tool tool-id="symfony" tool-name="Symfony"/>
490
490
</header>
491
491
<body>
492
- <trans-unit id="ypeBEso " resname="a">
492
+ <trans-unit id="%s " resname="a">
493
493
<source>a</source>
494
494
<target>trans_en_a</target>
495
495
</trans-unit>
@@ -518,7 +518,7 @@ public function testCompleteWriteProcessAddFileAndUploadTranslations(TranslatorB
518
518
$ this ->assertSame ('https://api.crowdin.com/api/v2/storages ' , $ url );
519
519
$ this ->assertSame ('Content-Type: application/octet-stream ' , $ options ['normalized_headers ' ]['content-type ' ][0 ]);
520
520
$ this ->assertSame ('Crowdin-API-FileName: messages.xlf ' , $ options ['normalized_headers ' ]['crowdin-api-filename ' ][0 ]);
521
- $ this ->assertSame ($ expectedMessagesFileContent , $ options ['body ' ]);
521
+ $ this ->assertStringMatchesFormat ($ expectedMessagesFileContent , $ options ['body ' ]);
522
522
523
523
return new JsonMockResponse (['data ' => ['id ' => 19 ]], ['http_code ' => 201 ]);
524
524
},
@@ -534,7 +534,7 @@ public function testCompleteWriteProcessAddFileAndUploadTranslations(TranslatorB
534
534
$ this ->assertSame ('https://api.crowdin.com/api/v2/storages ' , $ url );
535
535
$ this ->assertSame ('Content-Type: application/octet-stream ' , $ options ['normalized_headers ' ]['content-type ' ][0 ]);
536
536
$ this ->assertSame ('Crowdin-API-FileName: messages.xlf ' , $ options ['normalized_headers ' ]['crowdin-api-filename ' ][0 ]);
537
- $ this ->assertSame ($ expectedMessagesTranslationsContent , $ options ['body ' ]);
537
+ $ this ->assertStringMatchesFormat ($ expectedMessagesTranslationsContent , $ options ['body ' ]);
538
538
539
539
return new JsonMockResponse (['data ' => ['id ' => 19 ]], ['http_code ' => 201 ]);
540
540
},
@@ -575,7 +575,7 @@ public static function getResponsesForProcessAddFileAndUploadTranslations(): \Ge
575
575
<tool tool-id="symfony" tool-name="Symfony"/>
576
576
</header>
577
577
<body>
578
- <trans-unit id="ypeBEso " resname="a">
578
+ <trans-unit id="%s " resname="a">
579
579
<source>a</source>
580
580
<target>trans_fr_a</target>
581
581
</trans-unit>
@@ -602,7 +602,7 @@ public static function getResponsesForProcessAddFileAndUploadTranslations(): \Ge
602
602
<tool tool-id="symfony" tool-name="Symfony"/>
603
603
</header>
604
604
<body>
605
- <trans-unit id="ypeBEso " resname="a">
605
+ <trans-unit id="%s " resname="a">
606
606
<source>a</source>
607
607
<target>trans_en_gb_a</target>
608
608
</trans-unit>
0 commit comments