Skip to content

Commit 6554a2c

Browse files
Update guzzlehttp/psr7 requirement from ^1.2 to ^2.4 (#25)
* Update guzzlehttp/psr7 requirement from ^1.2 to ^2.4 Updates the requirements on [guzzlehttp/psr7](https://github.com/guzzle/psr7) to permit the latest version. - [Release notes](https://github.com/guzzle/psr7/releases) - [Changelog](https://github.com/guzzle/psr7/blob/master/CHANGELOG.md) - [Commits](guzzle/psr7@1.2.0...2.4.3) --- updated-dependencies: - dependency-name: guzzlehttp/psr7 dependency-type: direct:development ... Signed-off-by: dependabot[bot] <support@github.com> * Fix unit test using removed "uri_for" function --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Martin Helmich <kontakt@martin-helmich.de>
1 parent 02ae4bc commit 6554a2c

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
"psr/http-message": "^1.0"
1515
},
1616
"require-dev": {
17-
"guzzlehttp/psr7": "^1.2",
17+
"guzzlehttp/psr7": "^2.4",
1818
"mockery/mockery": "^1.4.1",
1919
"phpunit/phpunit": "^8.0 || ^9.0 || ^10.0"
2020
},

tests/Unit/Constraint/HasQueryParameterConstraintTest.php

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
namespace Helmich\Psr7Assert\Tests\Unit\Constraint;
44

55
use GuzzleHttp\Psr7\Request;
6+
use GuzzleHttp\Psr7\Uri;
67
use function GuzzleHttp\Psr7\uri_for;
78
use Helmich\Psr7Assert\Constraint\HasQueryParameterConstraint;
89
use PHPUnit\Framework\TestCase;
@@ -27,23 +28,23 @@ public function testMatchesStringUrlsNegative()
2728

2829
public function testMatchesPsr7Uris()
2930
{
30-
$uri = uri_for("https://some-domain.example/foo?bar=baz");
31+
$uri = new Uri("https://some-domain.example/foo?bar=baz");
3132
$constraint = new HasQueryParameterConstraint("bar", "baz");
3233

3334
self::assertThat($constraint->evaluate($uri, "", true), self::isTrue());
3435
}
3536

3637
public function testMatchesPsr7UrisNegative()
3738
{
38-
$uri = uri_for("https://some-domain.example/foo?autobahn=1");
39+
$uri = new Uri("https://some-domain.example/foo?autobahn=1");
3940
$constraint = new HasQueryParameterConstraint("bar", "baz");
4041

4142
self::assertThat($constraint->evaluate($uri, "", true), self::isFalse());
4243
}
4344

4445
public function testMatchesRequest()
4546
{
46-
$uri = uri_for("https://some-domain.example/foo?bar=baz");
47+
$uri = new Uri("https://some-domain.example/foo?bar=baz");
4748
$request = new Request("GET", $uri);
4849

4950
$constraint = new HasQueryParameterConstraint("bar", "baz");

0 commit comments

Comments
 (0)