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
registration: Add test to check extension.json globals are documented
[lhc/web/wiklou.git]
/
tests
/
phpunit
/
includes
/
TemplateParserTest.php
diff --git
a/tests/phpunit/includes/TemplateParserTest.php
b/tests/phpunit/includes/TemplateParserTest.php
index
ddef24a
..
469f45a
100644
(file)
--- a/
tests/phpunit/includes/TemplateParserTest.php
+++ b/
tests/phpunit/includes/TemplateParserTest.php
@@
-10,9
+10,9
@@
class TemplateParserTest extends MediaWikiTestCase {
protected function setUp() {
parent::setUp();
protected function setUp() {
parent::setUp();
- $this->setMwGlobals(
array(
+ $this->setMwGlobals(
[
'wgSecretKey' => 'foo',
'wgSecretKey' => 'foo',
-
)
);
+
]
);
$this->templateDir = dirname( __DIR__ ) . '/data/templates/';
}
$this->templateDir = dirname( __DIR__ ) . '/data/templates/';
}
@@
-32,44
+32,44
@@
class TemplateParserTest extends MediaWikiTestCase {
}
public static function provideProcessTemplate() {
}
public static function provideProcessTemplate() {
- return
array(
- array(
+ return
[
+ [
'foobar',
'foobar',
-
array()
,
+
[]
,
"hello world!\n"
"hello world!\n"
-
)
,
- array(
+
]
,
+ [
'foobar_args',
'foobar_args',
- array(
+ [
'planet' => 'world',
'planet' => 'world',
-
)
,
+
]
,
"hello world!\n",
"hello world!\n",
-
)
,
- array(
+
]
,
+ [
'../foobar',
'../foobar',
-
array()
,
+
[]
,
false,
'UnexpectedValueException'
false,
'UnexpectedValueException'
-
)
,
- array(
+
]
,
+ [
'nonexistenttemplate',
'nonexistenttemplate',
-
array()
,
+
[]
,
false,
'RuntimeException',
false,
'RuntimeException',
-
)
,
- array(
+
]
,
+ [
'has_partial',
'has_partial',
- array(
+ [
'planet' => 'world',
'planet' => 'world',
-
)
,
+
]
,
"Partial hello world!\n in here\n",
"Partial hello world!\n in here\n",
-
)
,
- array(
+
]
,
+ [
'bad_partial',
'bad_partial',
-
array()
,
+
[]
,
false,
'Exception',
false,
'Exception',
-
)
,
-
)
;
+
]
,
+
]
;
}
}
}
}