Skip to content

Commit

Permalink
DEP Use PHPUnit 11
Browse files Browse the repository at this point in the history
  • Loading branch information
emteknetnz committed Sep 6, 2024
1 parent ef4cbfe commit 8cd77f9
Show file tree
Hide file tree
Showing 8 changed files with 16 additions and 16 deletions.
2 changes: 1 addition & 1 deletion tests/Auth/HandlerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ public function testAuthenticatorsCanBePrioritised($authenticators, $expected)
/**
* @return array
*/
public function prioritisedAuthenticatorProvider()
public static function prioritisedAuthenticatorProvider()
{
return [
[
Expand Down
2 changes: 1 addition & 1 deletion tests/ControllerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ class ControllerTest extends SapphireTest
{
protected $usesDatabase = false;

public function providePrepareBacktrace()
public static function providePrepareBacktrace()
{
$querySource = <<<'GRAPHQL'
query ReadFiles($filter: FakeInputType!) {
Expand Down
2 changes: 1 addition & 1 deletion tests/Modules/AssetAdmin/ReadFileUsageQueryCreatorTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ protected function tearDown(): void
parent::tearDown();
}

public function fileUsageDataProvider()
public static function fileUsageDataProvider()
{
return [
[File::class, 'rootfile', 2, 'rootfile file is used twice'],
Expand Down
2 changes: 1 addition & 1 deletion tests/Modules/CMS/LinkablePluginTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ public function testResolver()
}


public function provideApply()
public static function provideApply()
{
return [
[true],
Expand Down
2 changes: 1 addition & 1 deletion tests/Schema/AbstractTypeRegistryTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ public function testRebuildOnMissing(
$this->assertSame($expected, $canRebuildOnMissingMethod->invoke($registry));
}

public function provideRebuildOnMissing(): array
public static function provideRebuildOnMissing(): array
{
// controller = current controller is a GraphQLController
// autobuild = if autobuild is enabled
Expand Down
2 changes: 1 addition & 1 deletion tests/Schema/DataObject/Plugin/FiltersTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ public function testFilterArguments(FieldFilterInterface $filter, string $identi
}
}

public function filterArgumentsProvider(): array
public static function filterArgumentsProvider(): array
{
return [
[
Expand Down
2 changes: 1 addition & 1 deletion tests/Schema/DataObject/Plugin/InheritanceTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ private function assertCalls(array $expected, array $actual)
$this->assertEmpty(array_diff($compare ?? [], $expected), 'Actual calls exceed the expected calls');
}

public function provideUnionOption()
public static function provideUnionOption()
{
return [
[true],
Expand Down
18 changes: 9 additions & 9 deletions tests/Schema/IntegrationTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -418,7 +418,7 @@ public function testNestedFieldDefinitions()
$this->assertMissingField($result, 'title');
}

public function provideFilterAndSort(): array
public static function provideFilterAndSort(): array
{
return [
[
Expand Down Expand Up @@ -671,7 +671,7 @@ public function testFieldAliases()
$this->assertResult('readOneDataObjectFake.author', null, $result);
}

public function provideFilterAndSortOnlyRead(): array
public static function provideFilterAndSortOnlyRead(): array
{
return [
'read with sort' => [
Expand Down Expand Up @@ -847,7 +847,7 @@ public function testFilterAndSortOnlyRead(string $fixture, string $query, array
$this->assertResults($expected, $records);
}

public function provideFilterAndSortWithArgsOnlyRead(): array
public static function provideFilterAndSortWithArgsOnlyRead(): array
{
return [
'read with sort - with sort arg' => [
Expand Down Expand Up @@ -1502,7 +1502,7 @@ public function testBulkLoadNamespaceAndFilepath()
/**
* @return array
*/
public function provideObfuscationState(): array
public static function provideObfuscationState(): array
{
return [ [false], [true] ];
}
Expand Down Expand Up @@ -1593,7 +1593,7 @@ public function testDefaultDepthLimit(int $queryDepth, int $limit)
}
}

public function provideDefaultDepthLimit()
public static function provideDefaultDepthLimit()
{
return $this->createProviderForComplexityOrDepth(15);
}
Expand All @@ -1614,7 +1614,7 @@ public function testCustomDepthLimit(int $queryDepth, int $limit)
}
}

public function provideCustomDepthLimit()
public static function provideCustomDepthLimit()
{
return $this->createProviderForComplexityOrDepth(25);
}
Expand All @@ -1635,7 +1635,7 @@ public function testCustomComplexityLimit(int $queryComplexity, int $limit)
}
}

public function provideCustomComplexityLimit()
public static function provideCustomComplexityLimit()
{
return $this->createProviderForComplexityOrDepth(10);
}
Expand All @@ -1649,7 +1649,7 @@ public function testDefaultNodeLimit(int $numNodes, int $limit)
$this->runNodeLimitTest($numNodes, $limit, $schema);
}

public function provideDefaultNodeLimit()
public static function provideDefaultNodeLimit()
{
return $this->createProviderForComplexityOrDepth(500);
}
Expand All @@ -1663,7 +1663,7 @@ public function testCustomNodeLimit(int $numNodes, int $limit)
$this->runNodeLimitTest($numNodes, $limit, $schema);
}

public function provideCustomNodeLimit()
public static function provideCustomNodeLimit()
{
return $this->createProviderForComplexityOrDepth(200);
}
Expand Down

0 comments on commit 8cd77f9

Please sign in to comment.