Skip to content

Commit

Permalink
Unskipped more tests.
Browse files Browse the repository at this point in the history
  • Loading branch information
ADmad committed Feb 25, 2014
1 parent 0d90958 commit 551bd9c
Showing 1 changed file with 10 additions and 13 deletions.
23 changes: 10 additions & 13 deletions tests/TestCase/View/Helper/FormHelperTest.php
Expand Up @@ -1175,7 +1175,6 @@ public function testFormSecurityFields() {
* @return void
*/
public function testTextFieldGenerationForFloats() {
$this->markTestIncomplete('Need to revisit once models work again.');
$this->article['schema'] = [
'foo' => [
'type' => 'float',
Expand All @@ -1185,17 +1184,17 @@ public function testTextFieldGenerationForFloats() {
]
];

$this->Form->create('Contact');
$this->Form->create($this->article);
$result = $this->Form->input('foo');
$expected = array(
'div' => array('class' => 'input number'),
'label' => array('for' => 'ContactFoo'),
'label' => array('for' => 'foo'),
'Foo',
'/label',
array('input' => array(
'type' => 'number',
'name' => 'Contact[foo]',
'id' => 'ContactFoo',
'name' => 'foo',
'id' => 'foo',
'step' => 'any'
)),
'/div'
Expand All @@ -1205,13 +1204,13 @@ public function testTextFieldGenerationForFloats() {
$result = $this->Form->input('foo', array('step' => 0.5));
$expected = array(
'div' => array('class' => 'input number'),
'label' => array('for' => 'ContactFoo'),
'label' => array('for' => 'foo'),
'Foo',
'/label',
array('input' => array(
'type' => 'number',
'name' => 'Contact[foo]',
'id' => 'ContactFoo',
'name' => 'foo',
'id' => 'foo',
'step' => '0.5'
)),
'/div'
Expand Down Expand Up @@ -1435,10 +1434,8 @@ public function testSecuritySubmitImageName() {
* @return void
*/
public function testFormSecurityMultipleInputFields() {
$this->markTestIncomplete('Need to revisit once models work again.');
$key = 'testKey';
$this->Form->request->params['_csrfToken'] = $key;
$this->Form->create('Addresses');
$this->Form->request->params['_Token'] = 'testKey';
$this->Form->create();

$this->Form->hidden('Addresses.0.id', array('value' => '123456'));
$this->Form->input('Addresses.0.title');
Expand Down Expand Up @@ -1470,7 +1467,7 @@ public function testFormSecurityMultipleInputFields() {
)),
array('input' => array(
'type' => 'hidden', 'name' => '_Token[unlocked]',
'value' => '', 'id' => 'preg:/TokenUnlocked\d+/'
'value' => ''
)),
'/div'
);
Expand Down

0 comments on commit 551bd9c

Please sign in to comment.