From e213e6402e65655163475aaaf54a0527b23a9a13 Mon Sep 17 00:00:00 2001 From: Dmitry Barsukov Date: Thu, 24 Jan 2019 13:17:17 +0700 Subject: [PATCH] Drop instanceof checks from tests --- tests/PhpHandlerTest.php | 9 +++++---- tests/WebspaceTest.php | 1 - 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/tests/PhpHandlerTest.php b/tests/PhpHandlerTest.php index 3cf413ac..e2202bb5 100644 --- a/tests/PhpHandlerTest.php +++ b/tests/PhpHandlerTest.php @@ -2,15 +2,14 @@ // Copyright 1999-2019. Plesk International GmbH. namespace PleskXTest; -use PleskX\Api\Struct\PhpHandler\Info; - class PhpHandlerTest extends TestCase { public function testGet() { $handler = static::$_client->phpHandler()->get(null, null); - $this->assertInstanceOf(Info::class, $handler); + $this->assertIsObject($handler); + $this->assertObjectHasAttribute('type', $handler); } public function testGetAll() @@ -21,7 +20,9 @@ public function testGetAll() $this->assertNotEmpty($handlers); $handler = current($handlers); - $this->assertInstanceOf(Info::class, $handler); + + $this->assertIsObject($handler); + $this->assertObjectHasAttribute('type', $handler); } /** diff --git a/tests/WebspaceTest.php b/tests/WebspaceTest.php index b2040b62..3546c804 100644 --- a/tests/WebspaceTest.php +++ b/tests/WebspaceTest.php @@ -133,7 +133,6 @@ public function testGet() $webspace = static::_createWebspace(); $webspaceInfo = static::$_client->webspace()->get('id', $webspace->id); - $this->assertInstanceOf(\PleskX\Api\Struct\Webspace\GeneralInfo::class, $webspaceInfo); $this->assertNotEmpty($webspaceInfo->name); $this->assertEquals(0, $webspaceInfo->realSize); }