Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
Signed-off-by: Mior Muhammad Zaki <crynobone@gmail.com>
  • Loading branch information
crynobone committed Dec 21, 2023
1 parent 1f86d0b commit f93ce19
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/Concerns/ApplicationTestingHooks.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@

trait ApplicationTestingHooks
{
use InteractsWithPHPUnit;
use InteractsWithTestCase;

/**
Expand Down
14 changes: 14 additions & 0 deletions src/Concerns/InteractsWithTestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

namespace Orchestra\Testbench\Concerns;

use Illuminate\Support\Collection;
use Orchestra\Testbench\Contracts\Attributes\AfterAll as AfterAllContract;
use Orchestra\Testbench\Contracts\Attributes\AfterEach as AfterEachContract;
use Orchestra\Testbench\Contracts\Attributes\BeforeAll as BeforeAllContract;
Expand Down Expand Up @@ -91,6 +92,19 @@ public static function usesTestingFeature($attribute): void
]);
}

/**
* Resolve PHPUnit method attributes for specific method.
*
* @phpunit-overrides
*
* @param class-string $className
* @param string|null $methodName
* @return \Illuminate\Support\Collection<class-string, array<int, object>>
*
* @phpstan-return \Illuminate\Support\Collection<class-string<TTestingFeature>, array<int, TTestingFeature>>
*/
abstract protected static function resolvePhpUnitAttributesForMethod(string $className, ?string $methodName = null): Collection;

/**
* Prepare the testing environment before the running the test case.
*
Expand Down

0 comments on commit f93ce19

Please sign in to comment.