Skip to content

Commit e21ec9e

Browse files
authored
Merge pull request #29 from rpkamp/support-httplug-2
Add support for HTTPlug 2.0
2 parents 255af79 + 15a1218 commit e21ec9e

File tree

2 files changed

+6
-5
lines changed

2 files changed

+6
-5
lines changed

composer.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,20 +24,20 @@
2424
"php": "^7.2",
2525
"ext-json": "*",
2626
"php-http/client-implementation": "^1.0",
27-
"php-http/httplug": "^1.0",
27+
"php-http/httplug": "^1.0|^2.0",
2828
"php-http/message-factory": "^1.0",
2929
"psr/http-message": "^1.0"
3030
},
3131
"require-dev": {
32-
"guzzlehttp/psr7": "^1.4",
3332
"jakub-onderka/php-parallel-lint": "^1.0",
3433
"phpmd/phpmd": "^2.1.2",
3534
"phpunit/phpunit": "^8.0",
36-
"php-http/curl-client": "^1.7",
35+
"php-http/curl-client": "^2.0",
3736
"squizlabs/php_codesniffer": "^3.4",
3837
"swiftmailer/swiftmailer": "^6.2",
3938
"phpstan/phpstan": "^0.11",
4039
"pdepend/pdepend": "^2.5",
41-
"maglnet/composer-require-checker": "^2.0"
40+
"maglnet/composer-require-checker": "^2.0",
41+
"nyholm/psr7": "^1.2"
4242
}
4343
}

tests/integration/MailhogClientTest.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
use Generator;
77
use Http\Client\Curl\Client;
88
use Http\Message\MessageFactory\GuzzleMessageFactory;
9+
use Nyholm\Psr7\Factory\HttplugFactory;
910
use PHPUnit\Framework\TestCase;
1011
use rpkamp\Mailhog\MailhogClient;
1112
use rpkamp\Mailhog\Message\Mime\Attachment;
@@ -30,7 +31,7 @@ class MailhogClientTest extends TestCase
3031

3132
public function setUp(): void
3233
{
33-
$this->client = new MailhogClient(new Client(), new GuzzleMessageFactory(), $_ENV['mailhog_api_uri']);
34+
$this->client = new MailhogClient(new Client(), new HttplugFactory(), $_ENV['mailhog_api_uri']);
3435
$this->client->purgeMessages();
3536
}
3637

0 commit comments

Comments
 (0)