FIX Update setUpBeforeClass and illegal_extensions

This commit is contained in:
Robbie Averill 2017-12-05 09:34:12 +13:00
parent a47d5e8a8e
commit 6ecf8439af
4 changed files with 16 additions and 12 deletions

View File

@ -15,10 +15,12 @@ use SilverStripe\FullTextSearch\Search\Processors\SearchUpdateQueuedJobProcessor
use SilverStripe\FullTextSearch\Search\Processors\SearchUpdateBatchedProcessor;
use SilverStripe\FullTextSearch\Search\Updaters\SearchUpdater;
use SilverStripe\FullTextSearch\Search\Variants\SearchVariantVersioned;
use SilverStripe\Subsites\Extensions\SiteTreeSubsites;
use SilverStripe\Subsites\Model\Subsite;
use SilverStripe\ORM\FieldType\DBDatetime;
use SilverStripe\Versioned\Versioned;
use Symbiote\QueuedJobs\Services\QueuedJob;
use Symbiote\QueuedJobs\Services\QueuedJobService;
use Symbiote\QueuedJobs\Services\QueuedJob;
/**
* Tests {@see SearchUpdateQueuedJobProcessor}
@ -29,9 +31,9 @@ class BatchedProcessorTest extends SapphireTest
protected $oldProcessor;
protected static $extra_dataobjects = array(
BatchedProcessorTest_Object::class
);
protected static $extra_dataobjects = [
BatchedProcessorTest_Object::class,
];
protected static $illegal_extensions = [
SiteTree::class => [
@ -203,7 +205,9 @@ class BatchedProcessorTest extends SapphireTest
*/
public function testSoftCap()
{
$this->markTestSkipped('@todo This test passes in isolation, but not in conjunction with the previous test');
$this->markTestSkipped(
'@todo PostgreSQL: This test passes in isolation, but not in conjunction with the previous test'
);
$index = singleton(BatchedProcessorTest_Index::class);
$index->reset();

View File

@ -31,9 +31,9 @@ class SearchVariantSubsiteTest extends SapphireTest
self::$index = singleton(static::class);
}
Config::inst()->update('Injector', 'SearchUpdateProcessor', array(
'class' => 'SearchUpdateImmediateProcessor'
));
Config::inst()->update(Injector::class, SearchUpdateProcessor::class, [
'class' => SearchUpdateImmediateProcessor::class
]);
FullTextSearch::force_index_list(self::$index);
SearchUpdater::clear_dirty_indexes();

View File

@ -55,9 +55,9 @@ class SolrIndexSubsitesTest extends SapphireTest
self::$index = singleton(SolrIndexSubsitesTest_Index::class);
}
Config::modify()->set('Injector', 'SearchUpdateProcessor', array(
'class' => 'SearchUpdateImmediateProcessor'
));
Config::modify()->set(Injector::class, SearchUpdateProcessor::class, [
'class' => SearchUpdateImmediateProcessor::class,
]);
FullTextSearch::force_index_list(self::$index);
SearchUpdater::clear_dirty_indexes();

View File

@ -46,7 +46,7 @@ class SolrIndexVersionedTest extends SapphireTest
self::$index = singleton(SolrVersionedTest_Index::class);
}
Config::modify()->set(Injector::class, SearchUpdateProcessor::class, array(
Config::modify()->set(Injector::class, SearchUpdateProcessor::class, [
'class' => SearchUpdateImmediateProcessor::class
]);