mirror of
https://github.com/silverstripe/silverstripe-translatable
synced 2024-10-22 11:05:59 +02:00
Removed testLocalePersistsInAllPageTypes()
Doesn't respect custom business logic such as validate() methods denying page creation to certain users, or page creation on the root level. The test doesn't add a whole lot of value, since the baseline translation creation doesn't really differ between page types.
This commit is contained in:
parent
522dff2487
commit
03311b4d00
@ -978,21 +978,6 @@ class TranslatableTest extends FunctionalTest {
|
||||
);
|
||||
}
|
||||
|
||||
function testLocalePersistsInAllPageTypes() {
|
||||
$types = ClassInfo::subclassesFor('SiteTree');
|
||||
foreach($types as $type) {
|
||||
if(singleton($type) instanceof TestOnly) continue;
|
||||
|
||||
$enPage = new $type();
|
||||
$enPage->Locale = 'en_US';
|
||||
$enPage->write();
|
||||
|
||||
$dePage = $enPage->createTranslation('de_DE');
|
||||
$dePage->write();
|
||||
$this->assertEquals('de_DE', $dePage->Locale, "Page type $type retains Locale property");
|
||||
}
|
||||
}
|
||||
|
||||
function testGetTranslationByStage() {
|
||||
$publishedPage = new SiteTree();
|
||||
$publishedPage->Locale = 'en_US';
|
||||
|
Loading…
Reference in New Issue
Block a user