X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=tests%2Fupdater%2FUpdaterTest.php;h=a6280b8c9b911a8d3b33ac0d4af2684304a49256;hb=f447edb73b1bcb52e86286467d3ec7b7bdc29948;hp=73029e07395cdab39040c7285f5273d29740f04d;hpb=ab58f2542072e6bf34acd862f6cfed84b33feb29;p=github%2Fshaarli%2FShaarli.git diff --git a/tests/updater/UpdaterTest.php b/tests/updater/UpdaterTest.php index 73029e07..a6280b8c 100644 --- a/tests/updater/UpdaterTest.php +++ b/tests/updater/UpdaterTest.php @@ -87,11 +87,10 @@ class UpdaterTest extends TestCase /** * Test errors in UpdaterUtils::write_updates_file(): empty updates file. - * - * @expectedException Exception */ public function testWriteEmptyUpdatesFile() { + $this->expectException(\Exception::class); $this->expectExceptionMessageRegExp('/Updates file path is not set(.*)/'); UpdaterUtils::write_updates_file('', array('test')); @@ -99,11 +98,10 @@ class UpdaterTest extends TestCase /** * Test errors in UpdaterUtils::write_updates_file(): not writable updates file. - * - * @expectedException Exception */ public function testWriteUpdatesFileNotWritable() { + $this->expectException(\Exception::class); $this->expectExceptionMessageRegExp('/Unable to write(.*)/'); $updatesFile = $this->conf->get('resource.data_dir') . '/updates.txt';