aboutsummaryrefslogtreecommitdiffhomepage
path: root/tests/config/ConfigJsonTest.php
diff options
context:
space:
mode:
authorArthurHoaro <arthur@hoa.ro>2020-09-29 15:00:11 +0200
committerArthurHoaro <arthur@hoa.ro>2020-09-29 18:57:22 +0200
commitab58f2542072e6bf34acd862f6cfed84b33feb29 (patch)
treea773a2ad2b98cd8e68c6f3c45c294e036cf3bd41 /tests/config/ConfigJsonTest.php
parenta5a9cf23acd1248585173aa32757d9720b5f2d62 (diff)
downloadShaarli-ab58f2542072e6bf34acd862f6cfed84b33feb29.tar.gz
Shaarli-ab58f2542072e6bf34acd862f6cfed84b33feb29.tar.zst
Shaarli-ab58f2542072e6bf34acd862f6cfed84b33feb29.zip
Compatibility with PHP 8
Diffstat (limited to 'tests/config/ConfigJsonTest.php')
-rw-r--r--tests/config/ConfigJsonTest.php13
1 files changed, 1 insertions, 12 deletions
diff --git a/tests/config/ConfigJsonTest.php b/tests/config/ConfigJsonTest.php
index 4f508925..c0ba5b8f 100644
--- a/tests/config/ConfigJsonTest.php
+++ b/tests/config/ConfigJsonTest.php
@@ -42,7 +42,7 @@ class ConfigJsonTest extends \Shaarli\TestCase
42 public function testReadInvalidJson() 42 public function testReadInvalidJson()
43 { 43 {
44 $this->expectException(\Exception::class); 44 $this->expectException(\Exception::class);
45 $this->expectExceptionMessageRegExp(' /An error occurred while parsing JSON configuration file \\([\\w\\/\\.]+\\): error code #4/'); 45 $this->expectExceptionMessageRegExp('/An error occurred while parsing JSON configuration file \\([\\w\\/\\.]+\\): error code #4/');
46 46
47 $this->configIO->read('tests/utils/config/configInvalid.json.php'); 47 $this->configIO->read('tests/utils/config/configInvalid.json.php');
48 } 48 }
@@ -111,17 +111,6 @@ class ConfigJsonTest extends \Shaarli\TestCase
111 /** 111 /**
112 * Write to invalid path. 112 * Write to invalid path.
113 */ 113 */
114 public function testWriteInvalidArray()
115 {
116 $this->expectException(\Shaarli\Exceptions\IOException::class);
117
118 $conf = array('conf' => 'value');
119 @$this->configIO->write(array(), $conf);
120 }
121
122 /**
123 * Write to invalid path.
124 */
125 public function testWriteInvalidBlank() 114 public function testWriteInvalidBlank()
126 { 115 {
127 $this->expectException(\Shaarli\Exceptions\IOException::class); 116 $this->expectException(\Shaarli\Exceptions\IOException::class);