From 5d23d894ae49c1f1e96899c1abd82ba9d94d82a8 Mon Sep 17 00:00:00 2001 From: Dane Everitt Date: Sun, 6 Dec 2020 12:25:36 -0800 Subject: [PATCH] Update NodeUpdateServiceTest.php --- tests/Unit/Services/Nodes/NodeUpdateServiceTest.php | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/tests/Unit/Services/Nodes/NodeUpdateServiceTest.php b/tests/Unit/Services/Nodes/NodeUpdateServiceTest.php index c8138185d..1a836e446 100644 --- a/tests/Unit/Services/Nodes/NodeUpdateServiceTest.php +++ b/tests/Unit/Services/Nodes/NodeUpdateServiceTest.php @@ -210,11 +210,8 @@ class NodeUpdateServiceTest extends TestCase try { $closure(); } catch (Exception $exception) { - $this->assertInstanceOf(DaemonConnectionException::class, $exception); - $this->assertSame( - 'There was an exception while attempting to communicate with the daemon resulting in a HTTP/E_CONN_REFUSED response code. This exception has been logged.', - $exception->getMessage() - ); + $this->assertInstanceOf(Exception::class, $exception); + $this->assertSame('Foo', $exception->getMessage()); return true; } @@ -224,9 +221,7 @@ class NodeUpdateServiceTest extends TestCase $this->repository->expects('withFreshModel->update')->andReturns($updatedModel); $this->configurationRepository->expects('setNode->update')->andThrow( - new DaemonConnectionException( - new TransferException('', 500, new Exception) - ) + new Exception('Foo') ); $this->getService()->handle($model, ['name' => $updatedModel->name]);