mirror of
https://github.com/symbiote/silverstripe-gridfieldextensions.git
synced 2024-10-22 17:05:39 +02:00
Add tests for 3 and 3.2 branches, support 5.6
Rename relations which are now physical methods in 3.2
This commit is contained in:
parent
1d25be7bdd
commit
8e56ed3e5a
10
.travis.yml
10
.travis.yml
@ -1,11 +1,19 @@
|
||||
language: php
|
||||
|
||||
sudo: false
|
||||
|
||||
php:
|
||||
- 5.3
|
||||
|
||||
env:
|
||||
- DB=MYSQL CORE_RELEASE=3.1
|
||||
- DB=MYSQL CORE_RELEASE=master
|
||||
|
||||
matrix:
|
||||
include:
|
||||
- php: 5.5
|
||||
env: DB=MYSQL CORE_RELEASE=3
|
||||
- php: 5.6
|
||||
env: DB=MYSQL CORE_RELEASE=3.2
|
||||
|
||||
before_script:
|
||||
- phpenv rehash
|
||||
|
@ -17,22 +17,22 @@ class GridFieldOrderableRowsTest extends SapphireTest {
|
||||
|
||||
$this->assertEquals(
|
||||
'GridFieldOrderableRowsTest_Ordered',
|
||||
$orderable->getSortTable($parent->HasMany())
|
||||
$orderable->getSortTable($parent->MyHasMany())
|
||||
);
|
||||
|
||||
$this->assertEquals(
|
||||
'GridFieldOrderableRowsTest_Ordered',
|
||||
$orderable->getSortTable($parent->HasManySubclass())
|
||||
$orderable->getSortTable($parent->MyHasManySubclass())
|
||||
);
|
||||
|
||||
$this->assertEquals(
|
||||
'GridFieldOrderableRowsTest_Ordered',
|
||||
$orderable->getSortTable($parent->ManyMany())
|
||||
$orderable->getSortTable($parent->MyManyMany())
|
||||
);
|
||||
|
||||
$this->assertEquals(
|
||||
'GridFieldOrderableRowsTest_Parent_ManyMany',
|
||||
$orderable->setSortField('ManyManySort')->getSortTable($parent->ManyMany())
|
||||
'GridFieldOrderableRowsTest_Parent_MyManyMany',
|
||||
$orderable->setSortField('ManyManySort')->getSortTable($parent->MyManyMany())
|
||||
);
|
||||
}
|
||||
|
||||
@ -45,16 +45,16 @@ class GridFieldOrderableRowsTest extends SapphireTest {
|
||||
class GridFieldOrderableRowsTest_Parent extends DataObject {
|
||||
|
||||
private static $has_many = array(
|
||||
'HasMany' => 'GridFieldOrderableRowsTest_Ordered',
|
||||
'HasManySubclass' => 'GridFieldOrderableRowsTest_Subclass'
|
||||
'MyHasMany' => 'GridFieldOrderableRowsTest_Ordered',
|
||||
'MyHasManySubclass' => 'GridFieldOrderableRowsTest_Subclass'
|
||||
);
|
||||
|
||||
private static $many_many = array(
|
||||
'ManyMany' => 'GridFieldOrderableRowsTest_Ordered'
|
||||
'MyManyMany' => 'GridFieldOrderableRowsTest_Ordered'
|
||||
);
|
||||
|
||||
private static $many_many_extraFields = array(
|
||||
'ManyMany' => array('ManyManySort' => 'Int')
|
||||
'MyManyMany' => array('ManyManySort' => 'Int')
|
||||
);
|
||||
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user