Skip to content
Permalink
Browse files

Integration test for using errors put directly on an entity is already

done, no need to have a duplicate
  • Loading branch information...
lorenzo committed Feb 27, 2014
1 parent 00ef8ed commit 2f5499d2cb42d6cedad5e97f937479a3271e3ceb
Showing with 0 additions and 40 deletions.
  1. +0 −40 tests/TestCase/View/Helper/FormHelperTest.php
@@ -2024,46 +2024,6 @@ public function testEmptyInputErrorValidation() {
$this->assertTags($result, $expected);
}
/**
* testFormValidationAssociated method
*
* test display of form errors in conjunction with model::validates.
*
* @return void
*/
public function testFormValidationAssociated() {
$this->markTestIncomplete('Need to revisit once models work again.');
$data = array(
'UserForm' => array('name' => 'user'),
'OpenidUrl' => array('url' => 'http://www.cakephp.org')
);
$result = $this->UserForm->OpenidUrl->create($data);
$this->assertFalse(empty($result));
$this->assertFalse($this->UserForm->OpenidUrl->validates());
$result = $this->Form->create('UserForm', array('type' => 'post', 'action' => 'login'));
$encoding = strtolower(Configure::read('App.encoding'));
$expected = array(
'form' => array(
'method' => 'post', 'action' => '/user_forms/login', 'id' => 'UserFormLoginForm',
'accept-charset' => $encoding
),
'div' => array('style' => 'display:none;'),
'input' => array('type' => 'hidden', 'name' => '_method', 'value' => 'POST'),
'/div'
);
$this->assertTags($result, $expected);
$result = $this->Form->error(
'OpenidUrl.openid_not_registered', 'Error, not registered', array('wrap' => false)
);
$this->assertEquals('Error, not registered', $result);
unset($this->UserForm->OpenidUrl, $this->UserForm);
}
/**
* testFormValidationAssociatedFirstLevel method
*

0 comments on commit 2f5499d

Please sign in to comment.
You can’t perform that action at this time.