diff --git a/cake/tests/cases/libs/view/helpers/form.test.php b/cake/tests/cases/libs/view/helpers/form.test.php index c17c2c69a7b..e0771e9037c 100644 --- a/cake/tests/cases/libs/view/helpers/form.test.php +++ b/cake/tests/cases/libs/view/helpers/form.test.php @@ -2021,6 +2021,19 @@ function testInputCheckboxesInLoop() { } } +/** + * test input name with leading integer, ensure attributes are generated correctly. + * + * @return void + */ + function testInputWithLeadingInteger() { + $result = $this->Form->text('0.Node.title'); + $expected = array( + 'input' => array('name' => 'data[0][Node][title]', 'id' => '0NodeTitle', 'type' => 'text') + ); + $this->assertTags($result, $expected); + } + /** * test form->input() with select type inputs. *