silverstripe-framework/tests/forms/FormActionTest.php
Damian Mooyman 8dd644d25d
API Namespace all classes
Namespace all templates
Move difflib and BBCodeParser2 to thirdparty
Remove deprecated API marked for removal in 4.0
2016-09-08 10:23:17 +12:00

21 lines
455 B
PHP

<?php
use SilverStripe\Dev\SapphireTest;
use SilverStripe\Forms\FormAction;
/**
* @package framework
* @subpackage tests
*/
class FormActionTest extends SapphireTest {
public function testGetField() {
$formAction = new FormAction('test');
$this->assertContains('type="submit"', $formAction->getAttributesHTML());
$formAction->setAttribute('src', 'file.png');
$this->assertContains('type="image"', $formAction->getAttributesHTML());
}
}