blob: 0f0231381b3a0d1e9d0f07ef3db1616e7f851576 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
|
<?php
class FileRepoTest extends MediaWikiTestCase {
/**
* @expectedException MWException
*/
function testFileRepoConstructionOptionCanNotBeNull() {
$f = new FileRepo();
}
/**
* @expectedException MWException
*/
function testFileRepoConstructionOptionCanNotBeAnEmptyArray() {
$f = new FileRepo( array() );
}
/**
* @expectedException MWException
*/
function testFileRepoConstructionOptionNeedNameKey() {
$f = new FileRepo( array(
'backend' => 'foobar'
) );
}
/**
* @expectedException MWException
*/
function testFileRepoConstructionOptionNeedBackendKey() {
$f = new FileRepo( array(
'name' => 'foobar'
) );
}
function testFileRepoConstructionWithRequiredOptions() {
$f = new FileRepo( array(
'name' => 'FileRepoTestRepository',
'backend' => 'local-backend',
));
$this->assertInstanceOf( 'FileRepo', $f );
}
}
|