File tree 1 file changed +18
-0
lines changed
src/Symfony/Component/Form/Tests/Extension/Core/Type
1 file changed +18
-0
lines changed Original file line number Diff line number Diff line change @@ -1994,6 +1994,24 @@ public function testStripLeadingUnderscoresAndDigitsFromId()
1994
1994
$ this ->assertEquals ('_09name ' , $ view ->vars ['full_name ' ]);
1995
1995
}
1996
1996
1997
+ public function testSubFormTranslationDomain ()
1998
+ {
1999
+ $ form = $ this ->factory ->create (static ::TESTED_TYPE , null , [
2000
+ 'label ' => 'label ' ,
2001
+ 'translation_domain ' => 'label_translation_domain ' ,
2002
+ 'choices ' => [
2003
+ 'choice1 ' => true ,
2004
+ 'choice2 ' => false ,
2005
+ ],
2006
+ 'choice_translation_domain ' => 'choice_translation_domain ' ,
2007
+ 'expanded ' => true ,
2008
+ ])->createView ();
2009
+
2010
+ $ this ->assertCount (2 , $ form ->children );
2011
+ $ this ->assertSame ('choice_translation_domain ' , $ form ->children [0 ]->vars ['translation_domain ' ]);
2012
+ $ this ->assertSame ('choice_translation_domain ' , $ form ->children [1 ]->vars ['translation_domain ' ]);
2013
+ }
2014
+
1997
2015
/**
1998
2016
* @dataProvider provideTrimCases
1999
2017
*/
You can’t perform that action at this time.
0 commit comments