function testFileRepoConstructionOptionCanNotBeNull() {
$f = new FileRepo();
}
+
/**
* @expectedException MWException
*/
function testFileRepoConstructionOptionCanNotBeAnEmptyArray() {
$f = new FileRepo( array() );
}
+
/**
* @expectedException MWException
*/
'backend' => 'foobar'
) );
}
+
/**
* @expectedException MWException
*/
) );
}
+ function testFileRepoConstructionWithRequiredOptions() {
+ $f = new FileRepo( array(
+ 'name' => 'FileRepoTestRepository',
+ 'backend' => new FSFileBackend( array(
+ 'name' => 'local-testing',
+ 'lockManager' => 'nullLockManager',
+ 'containerPaths' => array()
+ ) )
+ ) );
+ $this->assertInstanceOf( 'FileRepo', $f );
+ }
}