mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
8dd644d25d
Namespace all templates Move difflib and BBCodeParser2 to thirdparty Remove deprecated API marked for removal in 4.0
23 lines
669 B
PHP
23 lines
669 B
PHP
<?php
|
|
|
|
use SilverStripe\Dev\SapphireTest;
|
|
use SilverStripe\Forms\InlineFormAction;
|
|
|
|
|
|
/**
|
|
* Tests {@see InlineFormAction}
|
|
*/
|
|
class InlineFormActionTest extends SapphireTest {
|
|
|
|
public function testField() {
|
|
$action = new InlineFormAction('dothing', 'My Title', 'ss-action');
|
|
$html = (string)$action->Field();
|
|
$this->assertContains('<input', $html);
|
|
$this->assertContains('type="submit"', $html);
|
|
$this->assertContains('name="action_dothing"', $html);
|
|
$this->assertContains('value="My Title"', $html);
|
|
$this->assertContains('id="dothing"', $html);
|
|
$this->assertContains('class="action ss-action"', $html);
|
|
}
|
|
}
|