mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-02 14:18:46 +02:00
MINOR Fixed naming of test classes
This commit is contained in:
parent
e78419cef1
commit
033a1e593a
@ -4,7 +4,7 @@ class GridFieldToolbarHeaderTest extends SapphireTest {
|
|||||||
static $fixture_file = 'GridFieldToolbarHeaderTest.yml';
|
static $fixture_file = 'GridFieldToolbarHeaderTest.yml';
|
||||||
|
|
||||||
protected $extraDataObjects = array(
|
protected $extraDataObjects = array(
|
||||||
'GridFieldDetailFormTest_Company',
|
'GridFieldToolbarHeaderTest_Company',
|
||||||
);
|
);
|
||||||
|
|
||||||
public function testGridTitleAddNewEnabled() {
|
public function testGridTitleAddNewEnabled() {
|
||||||
@ -13,7 +13,7 @@ class GridFieldToolbarHeaderTest extends SapphireTest {
|
|||||||
$config = new GridFieldConfig();
|
$config = new GridFieldConfig();
|
||||||
$config->addComponent($titleField = new GridFieldToolbarHeader());
|
$config->addComponent($titleField = new GridFieldToolbarHeader());
|
||||||
$actions = new FieldList();
|
$actions = new FieldList();
|
||||||
$grid = new GridField('TestField', 'Test Field', new DataList('GridFieldDetailFormTest_Company'),$config);
|
$grid = new GridField('TestField', 'Test Field', new DataList('GridFieldToolbarHeaderTest_Company'),$config);
|
||||||
$fields = new FieldList($rootTab = new TabSet("Root",$tabMain = new Tab('Main',$grid)));
|
$fields = new FieldList($rootTab = new TabSet("Root",$tabMain = new Tab('Main',$grid)));
|
||||||
$form = new Form(Controller::curr(), "TestForm", $fields, $actions);
|
$form = new Form(Controller::curr(), "TestForm", $fields, $actions);
|
||||||
|
|
||||||
@ -28,7 +28,7 @@ class GridFieldToolbarHeaderTest extends SapphireTest {
|
|||||||
$config = new GridFieldConfig();
|
$config = new GridFieldConfig();
|
||||||
$config->addComponent($titleField = new GridFieldToolbarHeader());
|
$config->addComponent($titleField = new GridFieldToolbarHeader());
|
||||||
$actions = new FieldList();
|
$actions = new FieldList();
|
||||||
$grid = new GridField('TestField', 'Test Field', new DataList('GridFieldDetailFormTest_Company'),$config);
|
$grid = new GridField('TestField', 'Test Field', new DataList('GridFieldToolbarHeaderTest_Company'),$config);
|
||||||
$fields = new FieldList($rootTab = new TabSet("Root",$tabMain = new Tab('Main',$grid)));
|
$fields = new FieldList($rootTab = new TabSet("Root",$tabMain = new Tab('Main',$grid)));
|
||||||
$form = new Form(Controller::curr(), "TestForm", $fields, $actions);
|
$form = new Form(Controller::curr(), "TestForm", $fields, $actions);
|
||||||
|
|
||||||
@ -41,7 +41,7 @@ class GridFieldToolbarHeaderTest extends SapphireTest {
|
|||||||
if(Member::currentUser()) { Member::currentUser()->logOut(); }
|
if(Member::currentUser()) { Member::currentUser()->logOut(); }
|
||||||
$config = new GridFieldConfig();
|
$config = new GridFieldConfig();
|
||||||
$config->addComponent($titleField = new GridFieldToolbarHeader());
|
$config->addComponent($titleField = new GridFieldToolbarHeader());
|
||||||
$grid = new GridField('TestField', 'Test Field', new DataList('GridFieldDetailFormTest_Company'),$config);
|
$grid = new GridField('TestField', 'Test Field', new DataList('GridFieldToolbarHeaderTest_Company'),$config);
|
||||||
$fields = new FieldList(new TabSet("Root",$tabMain = new Tab('Main',$grid)));
|
$fields = new FieldList(new TabSet("Root",$tabMain = new Tab('Main',$grid)));
|
||||||
$form = new Form(Controller::curr(), "TestForm", $fields, new FieldList());
|
$form = new Form(Controller::curr(), "TestForm", $fields, new FieldList());
|
||||||
|
|
||||||
@ -49,7 +49,7 @@ class GridFieldToolbarHeaderTest extends SapphireTest {
|
|||||||
$this->assertNotContains('data-icon="add"', $html, "HTML should not contain the 'add new' button");
|
$this->assertNotContains('data-icon="add"', $html, "HTML should not contain the 'add new' button");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
class GridFieldDetailFormTest_Company extends DataObject implements TestOnly {
|
class GridFieldToolbarHeaderTest_Company extends DataObject implements TestOnly {
|
||||||
|
|
||||||
public static $db = array(
|
public static $db = array(
|
||||||
'Name' => 'Varchar(100)'
|
'Name' => 'Varchar(100)'
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
GridFieldDetailFormTest_Company:
|
GridFieldToolbarHeaderTest_Company:
|
||||||
test-company-1:
|
test-company-1:
|
||||||
Name: Test company 1
|
Name: Test company 1
|
||||||
test-company-2:
|
test-company-2:
|
||||||
|
Loading…
Reference in New Issue
Block a user