Skip to content

Commit 107b469

Browse files
pierredupfabpot
authored andcommitted
[DX] [Form] Add helper method to register form extensions during unit testing
1 parent 2d1b83d commit 107b469

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

Test/FormIntegrationTestCase.php

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,11 +29,29 @@ protected function setUp()
2929
{
3030
$this->factory = Forms::createFormFactoryBuilder()
3131
->addExtensions($this->getExtensions())
32+
->addTypeExtensions($this->getTypedExtensions())
33+
->addTypes($this->getTypes())
34+
->addTypeGuessers($this->getTypeGuessers())
3235
->getFormFactory();
3336
}
3437

3538
protected function getExtensions()
3639
{
3740
return array();
3841
}
42+
43+
protected function getTypedExtensions()
44+
{
45+
return array();
46+
}
47+
48+
protected function getTypes()
49+
{
50+
return array();
51+
}
52+
53+
protected function getTypeGuessers()
54+
{
55+
return array();
56+
}
3957
}

0 commit comments

Comments
 (0)