diff --git a/ApnsPHP/Tests/PushConnectTest.php b/ApnsPHP/Tests/PushConnectTest.php index 716038a9..389c1e96 100644 --- a/ApnsPHP/Tests/PushConnectTest.php +++ b/ApnsPHP/Tests/PushConnectTest.php @@ -12,6 +12,7 @@ use ApnsPHP\Exception; use stdClass; +use Throwable; /** * This class contains tests for the connect function @@ -90,6 +91,12 @@ public function testConnectThrowsExceptionOnHttpInitFail(): void $this->expectException('ApnsPHP\Exception'); $this->expectExceptionMessage('Unable to initialize HTTP/2 backend.'); - $this->class->connect(); + try { + $this->class->connect(); + } catch (Throwable $e) { + $this->unmock_function('curl_setopt_array'); + + throw $e; + } } } diff --git a/phpunit.xml b/phpunit.xml index cd69d04d..10806f66 100644 --- a/phpunit.xml +++ b/phpunit.xml @@ -12,31 +12,10 @@ - ApnsPHP/Tests/MessageSetTest.php - ApnsPHP/Tests/MessageGetTest.php - ApnsPHP/Tests/MessageAddRecipientTest.php - ApnsPHP/Tests/MessageSelfForRecipientTest.php - ApnsPHP/Tests/MessageGetPayloadDictionaryTest.php - ApnsPHP/Tests/MessageGetPayloadTest.php - ApnsPHP/Tests/PushGetTest.php - ApnsPHP/Tests/PushSetTest.php - ApnsPHP/Tests/PushDisconnectTest.php - ApnsPHP/Tests/PushHttpInitTest.php - ApnsPHP/Tests/PushConnectTest.php - ApnsPHP/Tests/PushAddTest.php - ApnsPHP/Tests/PushSendTest.php - ApnsPHP/Tests/PushHttpSendTest.php - ApnsPHP/Tests/PushUpdateQueueTest.php - ApnsPHP/Tests/PushRemoveMessageFromQueueTest.php - ApnsPHP/Tests/PushInvalidTest.php + ApnsPHP/Tests/ - ApnsPHP/Message/Tests/CustomMessageTest.php - ApnsPHP/Message/Tests/CustomMessageGetTest.php - ApnsPHP/Message/Tests/CustomMessageGetPayloadDictionaryTest.php - ApnsPHP/Message/Tests/SafariMessageTest.php - ApnsPHP/Message/Tests/SafariMessageGetTest.php - ApnsPHP/Message/Tests/SafariMessageGetPayloadDictionaryTest.php + ApnsPHP/Message/Tests/