Adding test for #2325

git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@4734 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
dho 2007-04-01 15:07:27 +00:00
parent c276d65d6f
commit 20be70a22e

View file

@ -223,6 +223,16 @@ class FormHelperTest extends UnitTestCase {
} }
function testHour() {
$result = $this->Form->hour('tagname', false);
$this->assertPattern('/option value="12"/', $result);
$this->assertNoPattern('/option value="13"/', $result);
$result = $this->Form->hour('tagname', true);
$this->assertPattern('/option value="23"/', $result);
$this->assertNoPattern('/option value="24"/', $result);
}
function testYear() { function testYear() {
$result = $this->Form->year('Model.field', 2006, 2007); $result = $this->Form->year('Model.field', 2006, 2007);
$this->assertPattern('/option value="2006"/', $result); $this->assertPattern('/option value="2006"/', $result);