$manager = \TestingAccessWrapper::newFromObject( $this->getManager() );
$this->assertSame( $this->config, $manager->config );
$this->assertSame( $this->logger, $manager->logger );
- $this->assertSame( $this->store, $manager->permStore );
+ $this->assertSame( $this->store, $manager->store );
$manager = \TestingAccessWrapper::newFromObject( new SessionManager() );
$this->assertSame( \RequestContext::getMain()->getConfig(), $manager->config );
$manager = \TestingAccessWrapper::newFromObject( new SessionManager( array(
'config' => $this->config,
) ) );
- $this->assertSame( \ObjectCache::$instances['testSessionStore'], $manager->permStore );
+ $this->assertSame( \ObjectCache::$instances['testSessionStore'], $manager->store );
foreach ( array(
'config' => '$options[\'config\'] must be an instance of Config',
public function testGetSessionById() {
$manager = $this->getManager();
-
- // Disable the in-process cache so our $this->store->setSession() takes effect.
- \TestingAccessWrapper::newFromObject( $manager )->tempStore = new \EmptyBagOStuff;
-
try {
$manager->getSessionById( 'bad' );
$this->fail( 'Expected exception not thrown' );
'Bar' => array( 'X', 'Bar1', 3 => 'Bar2' ),
'Quux' => array( 'Quux' ),
'Baz' => array(),
- 'Quux' => array( 'Quux' ),
);
$this->assertEquals( $expect, $manager->getVaryHeaders() );
$that = $this;
- \ObjectCache::$instances[__METHOD__] = new \HashBagOStuff();
+ \ObjectCache::$instances[__METHOD__] = new TestBagOStuff();
$this->setMwGlobals( array( 'wgMainCacheType' => __METHOD__ ) );
$this->stashMwGlobals( array( 'wgGroupPermissions' ) );
$manager->setLogger( $logger );
$request = new \FauxRequest();
- // Disable the in-process cache so our $this->store->setSession() takes effect.
- \TestingAccessWrapper::newFromObject( $manager )->tempStore = new \EmptyBagOStuff;
-
// TestingAccessWrapper can't handle methods with reference arguments, sigh.
$rClass = new \ReflectionClass( $manager );
$rMethod = $rClass->getMethod( 'loadSessionInfoFromStore' );