Skip to content

Commit 2e8b9ce

Browse files
committed
fix test
1 parent 0dfaf96 commit 2e8b9ce

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

src/Symfony/Component/Mime/Tests/Part/Multipart/FormDataPartTest.php

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -244,11 +244,13 @@ public function testBoundaryContentTypeHeader()
244244
);
245245
}
246246

247-
public function testConstructThrowsOnUnexpectedFieldType()
247+
public function testGetPartsThrowsOnUnexpectedFieldType()
248248
{
249+
$dataPart = new FormDataPart(['foo' => new \stdClass()]);
250+
249251
$this->expectException(InvalidArgumentException::class);
250-
$this->expectExceptionMessage('A form field value can only be a string, an array, or an instance of TextPart ("stdClass" given).');
252+
$this->expectExceptionMessage('The value of the form field "foo" can only be a string, an array, or an instance of TextPart, "stdClass" given.');
251253

252-
new FormDataPart(['foo' => new \stdClass()]);
254+
$dataPart->getParts();
253255
}
254256
}

0 commit comments

Comments
 (0)