Skip to content

Commit

Permalink
Migrate to static data providers using rector/rector
Browse files Browse the repository at this point in the history
  • Loading branch information
OskarStark authored and nicolas-grekas committed Feb 14, 2023
1 parent 1ef0c5c commit 1504b67
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion Tests/PackageTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ public function testGetUrl($version, $format, $path, $expected)
$this->assertSame($expected, $package->getUrl($path));
}

public function getConfigs()
public static function getConfigs()
{
return [
['v1', '', 'http://example.com/foo', 'http://example.com/foo'],
Expand Down
4 changes: 2 additions & 2 deletions Tests/PathPackageTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ public function testGetUrl($basePath, $format, $path, $expected)
$this->assertSame($expected, $package->getUrl($path));
}

public function getConfigs()
public static function getConfigs()
{
return [
['/foo', '', 'http://example.com/foo', 'http://example.com/foo'],
Expand Down Expand Up @@ -60,7 +60,7 @@ public function testGetUrlWithContext($basePathRequest, $basePath, $format, $pat
$this->assertSame($expected, $package->getUrl($path));
}

public function getContextConfigs()
public static function getContextConfigs()
{
return [
['', '/foo', '', '/baz', '/baz?v1'],
Expand Down
6 changes: 3 additions & 3 deletions Tests/UrlPackageTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public function testGetUrl($baseUrls, $format, $path, $expected)
$this->assertSame($expected, $package->getUrl($path));
}

public function getConfigs()
public static function getConfigs()
{
return [
['http://example.net', '', 'http://example.com/foo', 'http://example.com/foo'],
Expand Down Expand Up @@ -72,7 +72,7 @@ public function testGetUrlWithContext($secure, $baseUrls, $format, $path, $expec
$this->assertSame($expected, $package->getUrl($path));
}

public function getContextConfigs()
public static function getContextConfigs()
{
return [
[false, 'http://example.com', '', 'foo', 'http://example.com/foo?v1'],
Expand Down Expand Up @@ -114,7 +114,7 @@ public function testWrongBaseUrl($baseUrls)
new UrlPackage($baseUrls, new EmptyVersionStrategy());
}

public function getWrongBaseUrlConfig()
public static function getWrongBaseUrlConfig()
{
return [
['not-a-url'],
Expand Down
2 changes: 1 addition & 1 deletion Tests/VersionStrategy/StaticVersionStrategyTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ public function testApplyVersion($path, $version, $format)
$this->assertSame($formatted, $staticVersionStrategy->applyVersion($path));
}

public function getConfigs()
public static function getConfigs()
{
return [
['test-path', 'v1', null],
Expand Down

0 comments on commit 1504b67

Please sign in to comment.