dépôts
/
lhc
/
web
/
wiklou.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge "createNoOpMock() method for PHPUnit tests"
[lhc/web/wiklou.git]
/
tests
/
phpunit
/
includes
/
objectcache
/
ObjectCacheTest.php
diff --git
a/tests/phpunit/includes/objectcache/ObjectCacheTest.php
b/tests/phpunit/includes/objectcache/ObjectCacheTest.php
index
4318852
..
7f52ca6
100644
(file)
--- a/
tests/phpunit/includes/objectcache/ObjectCacheTest.php
+++ b/
tests/phpunit/includes/objectcache/ObjectCacheTest.php
@@
-82,9
+82,6
@@
class ObjectCacheTest extends MediaWikiTestCase {
/** @covers ObjectCache::newAnything */
public function testNewAnythingNoAccelNoDb() {
/** @covers ObjectCache::newAnything */
public function testNewAnythingNoAccelNoDb() {
- $this->overrideMwServices(); // Ensures restore on tear down
- MediaWiki\MediaWikiServices::disableStorageBackend();
-
$this->setMwGlobals( [
'wgMainCacheType' => CACHE_ACCEL
] );
$this->setMwGlobals( [
'wgMainCacheType' => CACHE_ACCEL
] );
@@
-94,6
+91,8
@@
class ObjectCacheTest extends MediaWikiTestCase {
CACHE_ACCEL => [ 'class' => EmptyBagOStuff::class ]
] );
CACHE_ACCEL => [ 'class' => EmptyBagOStuff::class ]
] );
+ MediaWiki\MediaWikiServices::disableStorageBackend();
+
$this->assertInstanceOf(
EmptyBagOStuff::class,
ObjectCache::newAnything( [] ),
$this->assertInstanceOf(
EmptyBagOStuff::class,
ObjectCache::newAnything( [] ),
@@
-103,7
+102,6
@@
class ObjectCacheTest extends MediaWikiTestCase {
/** @covers ObjectCache::newAnything */
public function testNewAnythingNothingNoDb() {
/** @covers ObjectCache::newAnything */
public function testNewAnythingNothingNoDb() {
- $this->overrideMwServices();
MediaWiki\MediaWikiServices::disableStorageBackend();
$this->assertInstanceOf(
MediaWiki\MediaWikiServices::disableStorageBackend();
$this->assertInstanceOf(