diff options
author | Bernhard Posselt <dev@bernhard-posselt.com> | 2014-05-14 17:32:49 +0200 |
---|---|---|
committer | Bernhard Posselt <dev@bernhard-posselt.com> | 2014-05-14 17:32:49 +0200 |
commit | 160a0dfebaeb21cc75d7166dfbac6d0ef1a51460 (patch) | |
tree | 28e2555c97462d60356ef933d5c71c5326649747 /tests/unit/utility | |
parent | acc2df1251a1c1b9ec5ede13bdf46d516dc64b0d (diff) |
convert array() to []
Diffstat (limited to 'tests/unit/utility')
-rw-r--r-- | tests/unit/utility/ConfigTest.php | 6 | ||||
-rw-r--r-- | tests/unit/utility/OPMLExporterTest.php | 13 |
2 files changed, 9 insertions, 10 deletions
diff --git a/tests/unit/utility/ConfigTest.php b/tests/unit/utility/ConfigTest.php index 8c1bee0f0..8a3173732 100644 --- a/tests/unit/utility/ConfigTest.php +++ b/tests/unit/utility/ConfigTest.php @@ -28,12 +28,12 @@ class ConfigTest extends \PHPUnit_Framework_TestCase { '\OCP\ILogger') ->disableOriginalConstructor() ->getMock(); - $this->fileSystem = $this->getMock('FileSystem', array( + $this->fileSystem = $this->getMock('FileSystem', [ 'file_get_contents', 'file_put_contents', 'file_exists' - )); - $this->loggerParams = array('hi'); + ]); + $this->loggerParams = ['hi']; $this->config = new Config($this->fileSystem, $this->logger, $this->loggerParams); $this->configPath = 'config.json'; } diff --git a/tests/unit/utility/OPMLExporterTest.php b/tests/unit/utility/OPMLExporterTest.php index 958beaaa8..1ff812aa7 100644 --- a/tests/unit/utility/OPMLExporterTest.php +++ b/tests/unit/utility/OPMLExporterTest.php @@ -48,7 +48,7 @@ class OPMLExporterTest extends \PHPUnit_Framework_TestCase { public function testBuildEmpty(){ - $result = $this->exporter->build(array(), array()); + $result = $this->exporter->build([], []); $xpath = new \DOMXpath($result); $this->assertEquals(0, $xpath->query('//outline')->length); @@ -56,8 +56,7 @@ class OPMLExporterTest extends \PHPUnit_Framework_TestCase { public function testBuildReturnsFolders() { - $result = $this->exporter->build(array( - $this->folder1, $this->folder2), array()); + $result = $this->exporter->build([$this->folder1, $this->folder2], []); $xpath = new \DOMXpath($result); $elems = $xpath->query('/opml/body/outline'); @@ -70,8 +69,7 @@ class OPMLExporterTest extends \PHPUnit_Framework_TestCase { public function testBuildReturnsOnlyOneFeedIfParentFolderNotThere() { - $result = $this->exporter->build(array(), - array($this->feed1, $this->feed2)); + $result = $this->exporter->build([], [$this->feed1, $this->feed2]); $xpath = new \DOMXpath($result); $elems = $xpath->query('//outline'); @@ -85,8 +83,9 @@ class OPMLExporterTest extends \PHPUnit_Framework_TestCase { public function testBuildReturnsFeedsAndFolders() { $result = $this->exporter->build( - array($this->folder1, $this->folder2), - array($this->feed1, $this->feed2)); + [$this->folder1, $this->folder2], + [$this->feed1, $this->feed2] + ); $xpath = new \DOMXpath($result); $elems = $xpath->query('/opml/body/outline'); |