mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-03-18 15:39:53 +00:00
Adding test for form->submit() and timestamps.
Conflicts: lib/Cake/Test/Case/View/Helper/FormHelperTest.php
This commit is contained in:
parent
30504ef32b
commit
edfb0884c8
1 changed files with 17 additions and 0 deletions
|
@ -6009,6 +6009,23 @@ class FormHelperTest extends CakeTestCase {
|
||||||
$this->assertEquals(array('save'), $result, 'Only submits with name attributes should be unlocked.');
|
$this->assertEquals(array('save'), $result, 'Only submits with name attributes should be unlocked.');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Test submit image with timestamps.
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
|
*/
|
||||||
|
function testSubmitImageTimestamp() {
|
||||||
|
Configure::write('Asset.timestamp', 'force');
|
||||||
|
|
||||||
|
$result = $this->Form->submit('cake.power.gif');
|
||||||
|
$expected = array(
|
||||||
|
'div' => array('class' => 'submit'),
|
||||||
|
'input' => array('type' => 'image', 'src' => 'preg:/img\/cake\.power\.gif\?\d*/'),
|
||||||
|
'/div'
|
||||||
|
);
|
||||||
|
$this->assertTags($result, $expected);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* test the create() method
|
* test the create() method
|
||||||
*
|
*
|
||||||
|
|
Loading…
Add table
Reference in a new issue