public function testSetFormatWithOptions() { $format = 'Y-m-d'; $element = new DateTimeElement('foo'); $element->setOptions(array('format' => $format)); $this->assertSame($format, $element->getFormat()); }
public function testUsesBrowserFormatByDefault() { $element = new DateTimeElement('foo'); $this->assertEquals(DateTimeElement::DATETIME_FORMAT, $element->getFormat()); }
public function testUsesRfc3339FormatByDefault() { $element = new DateTimeElement('foo'); $this->assertEquals(DateTime::RFC3339, $element->getFormat()); }