@@ -186,11 +186,11 @@ public function testFile()
186
186
$ response = $ controller ->file (new File (__FILE__ ));
187
187
$ this ->assertInstanceOf (BinaryFileResponse::class, $ response );
188
188
$ this ->assertSame (200 , $ response ->getStatusCode ());
189
- if ($ response ->headers ->get ('content-type ' )) {
190
- $ this ->assertSame ('text/x-php ' , $ response ->headers ->get ('content-type ' ));
189
+ if ($ response ->headers ->getValue ('content-type ' )) {
190
+ $ this ->assertSame ('text/x-php ' , $ response ->headers ->getValue ('content-type ' ));
191
191
}
192
- $ this ->assertContains (ResponseHeaderBag::DISPOSITION_ATTACHMENT , $ response ->headers ->get ('content-disposition ' ));
193
- $ this ->assertContains (basename (__FILE__ ), $ response ->headers ->get ('content-disposition ' ));
192
+ $ this ->assertContains (ResponseHeaderBag::DISPOSITION_ATTACHMENT , $ response ->headers ->getValue ('content-disposition ' ));
193
+ $ this ->assertContains (basename (__FILE__ ), $ response ->headers ->getValue ('content-disposition ' ));
194
194
}
195
195
196
196
public function testFileAsInline ()
@@ -202,11 +202,11 @@ public function testFileAsInline()
202
202
203
203
$ this ->assertInstanceOf (BinaryFileResponse::class, $ response );
204
204
$ this ->assertSame (200 , $ response ->getStatusCode ());
205
- if ($ response ->headers ->get ('content-type ' )) {
206
- $ this ->assertSame ('text/x-php ' , $ response ->headers ->get ('content-type ' ));
205
+ if ($ response ->headers ->getValue ('content-type ' )) {
206
+ $ this ->assertSame ('text/x-php ' , $ response ->headers ->getValue ('content-type ' ));
207
207
}
208
- $ this ->assertContains (ResponseHeaderBag::DISPOSITION_INLINE , $ response ->headers ->get ('content-disposition ' ));
209
- $ this ->assertContains (basename (__FILE__ ), $ response ->headers ->get ('content-disposition ' ));
208
+ $ this ->assertContains (ResponseHeaderBag::DISPOSITION_INLINE , $ response ->headers ->getValue ('content-disposition ' ));
209
+ $ this ->assertContains (basename (__FILE__ ), $ response ->headers ->getValue ('content-disposition ' ));
210
210
}
211
211
212
212
public function testFileWithOwnFileName ()
@@ -219,11 +219,11 @@ public function testFileWithOwnFileName()
219
219
220
220
$ this ->assertInstanceOf (BinaryFileResponse::class, $ response );
221
221
$ this ->assertSame (200 , $ response ->getStatusCode ());
222
- if ($ response ->headers ->get ('content-type ' )) {
223
- $ this ->assertSame ('text/x-php ' , $ response ->headers ->get ('content-type ' ));
222
+ if ($ response ->headers ->getValue ('content-type ' )) {
223
+ $ this ->assertSame ('text/x-php ' , $ response ->headers ->getValue ('content-type ' ));
224
224
}
225
- $ this ->assertContains (ResponseHeaderBag::DISPOSITION_ATTACHMENT , $ response ->headers ->get ('content-disposition ' ));
226
- $ this ->assertContains ($ fileName , $ response ->headers ->get ('content-disposition ' ));
225
+ $ this ->assertContains (ResponseHeaderBag::DISPOSITION_ATTACHMENT , $ response ->headers ->getValue ('content-disposition ' ));
226
+ $ this ->assertContains ($ fileName , $ response ->headers ->getValue ('content-disposition ' ));
227
227
}
228
228
229
229
public function testFileWithOwnFileNameAsInline ()
@@ -236,11 +236,11 @@ public function testFileWithOwnFileNameAsInline()
236
236
237
237
$ this ->assertInstanceOf (BinaryFileResponse::class, $ response );
238
238
$ this ->assertSame (200 , $ response ->getStatusCode ());
239
- if ($ response ->headers ->get ('content-type ' )) {
240
- $ this ->assertSame ('text/x-php ' , $ response ->headers ->get ('content-type ' ));
239
+ if ($ response ->headers ->getValue ('content-type ' )) {
240
+ $ this ->assertSame ('text/x-php ' , $ response ->headers ->getValue ('content-type ' ));
241
241
}
242
- $ this ->assertContains (ResponseHeaderBag::DISPOSITION_INLINE , $ response ->headers ->get ('content-disposition ' ));
243
- $ this ->assertContains ($ fileName , $ response ->headers ->get ('content-disposition ' ));
242
+ $ this ->assertContains (ResponseHeaderBag::DISPOSITION_INLINE , $ response ->headers ->getValue ('content-disposition ' ));
243
+ $ this ->assertContains ($ fileName , $ response ->headers ->getValue ('content-disposition ' ));
244
244
}
245
245
246
246
public function testFileFromPath ()
@@ -252,11 +252,11 @@ public function testFileFromPath()
252
252
253
253
$ this ->assertInstanceOf (BinaryFileResponse::class, $ response );
254
254
$ this ->assertSame (200 , $ response ->getStatusCode ());
255
- if ($ response ->headers ->get ('content-type ' )) {
256
- $ this ->assertSame ('text/x-php ' , $ response ->headers ->get ('content-type ' ));
255
+ if ($ response ->headers ->getValue ('content-type ' )) {
256
+ $ this ->assertSame ('text/x-php ' , $ response ->headers ->getValue ('content-type ' ));
257
257
}
258
- $ this ->assertContains (ResponseHeaderBag::DISPOSITION_ATTACHMENT , $ response ->headers ->get ('content-disposition ' ));
259
- $ this ->assertContains (basename (__FILE__ ), $ response ->headers ->get ('content-disposition ' ));
258
+ $ this ->assertContains (ResponseHeaderBag::DISPOSITION_ATTACHMENT , $ response ->headers ->getValue ('content-disposition ' ));
259
+ $ this ->assertContains (basename (__FILE__ ), $ response ->headers ->getValue ('content-disposition ' ));
260
260
}
261
261
262
262
public function testFileFromPathWithCustomizedFileName ()
@@ -268,11 +268,11 @@ public function testFileFromPathWithCustomizedFileName()
268
268
269
269
$ this ->assertInstanceOf (BinaryFileResponse::class, $ response );
270
270
$ this ->assertSame (200 , $ response ->getStatusCode ());
271
- if ($ response ->headers ->get ('content-type ' )) {
272
- $ this ->assertSame ('text/x-php ' , $ response ->headers ->get ('content-type ' ));
271
+ if ($ response ->headers ->getValue ('content-type ' )) {
272
+ $ this ->assertSame ('text/x-php ' , $ response ->headers ->getValue ('content-type ' ));
273
273
}
274
- $ this ->assertContains (ResponseHeaderBag::DISPOSITION_ATTACHMENT , $ response ->headers ->get ('content-disposition ' ));
275
- $ this ->assertContains ('test.php ' , $ response ->headers ->get ('content-disposition ' ));
274
+ $ this ->assertContains (ResponseHeaderBag::DISPOSITION_ATTACHMENT , $ response ->headers ->getValue ('content-disposition ' ));
275
+ $ this ->assertContains ('test.php ' , $ response ->headers ->getValue ('content-disposition ' ));
276
276
}
277
277
278
278
/**
0 commit comments