Permalink
Browse files

Adding test for form->submit() and timestamps.

  • Loading branch information...
markstory committed Oct 20, 2011
1 parent 76e6452 commit 4e37c792fb0d69130e1b510e9ac667f25da7b5ef
Showing with 17 additions and 0 deletions.
  1. +17 −0 cake/tests/cases/libs/view/helpers/form.test.php
@@ -5653,6 +5653,23 @@ function testSubmitImage() {
$this->assertTags($result, $expected);
}
/**
* 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
*

0 comments on commit 4e37c79

Please sign in to comment.