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 4, 2024
1 parent b4ee54d commit 896c2e6
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 10 deletions.
2 changes: 0 additions & 2 deletions src/Concerns/HandlesDatabases.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,7 @@
use Illuminate\Database\Events\DatabaseRefreshed;
use Orchestra\Testbench\Attributes\DefineDatabase;
use Orchestra\Testbench\Attributes\WithMigration;
use Orchestra\Testbench\Exceptions\ApplicationNotAvailableException;
use Orchestra\Testbench\Features\TestingFeature;
use Orchestra\Testbench\Foundation\Application;

use function Orchestra\Testbench\laravel_or_fail;

Expand Down
1 change: 0 additions & 1 deletion src/Concerns/InteractsWithMigrations.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
use InvalidArgumentException;
use Orchestra\Testbench\Attributes\ResetRefreshDatabaseState;
use Orchestra\Testbench\Database\MigrateProcessor;
use Orchestra\Testbench\Exceptions\ApplicationNotAvailableException;

use function Orchestra\Testbench\default_migration_path;
use function Orchestra\Testbench\laravel_or_fail;
Expand Down
3 changes: 1 addition & 2 deletions src/Concerns/InteractsWithTestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
use Orchestra\Testbench\Contracts\Attributes\BeforeAll as BeforeAllContract;
use Orchestra\Testbench\Contracts\Attributes\BeforeEach as BeforeEachContract;
use Orchestra\Testbench\Contracts\Attributes\Resolvable as ResolvableContract;
use Orchestra\Testbench\Exceptions\ApplicationNotAvailableException;
use Orchestra\Testbench\PHPUnit\AttributeParser;

use function Orchestra\Testbench\laravel_or_fail;
Expand Down Expand Up @@ -144,7 +143,7 @@ protected function setUpTheTestEnvironmentUsingTestCase(): void
protected function tearDownTheTestEnvironmentUsingTestCase(): void
{
$app = laravel_or_fail($this->app);

$this->resolvePhpUnitAttributes()
->flatten()
->filter(static fn ($instance) => $instance instanceof AfterEachContract)
Expand Down
1 change: 0 additions & 1 deletion src/Foundation/Application.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
use Illuminate\Console\Application as Artisan;
use Illuminate\Console\Scheduling\ScheduleListCommand;
use Illuminate\Console\Signals;
use Illuminate\Foundation\Application as LaravelApplication;
use Illuminate\Foundation\Bootstrap\HandleExceptions;
use Illuminate\Foundation\Bootstrap\LoadEnvironmentVariables;
use Illuminate\Foundation\Console\RouteListCommand;
Expand Down
8 changes: 4 additions & 4 deletions src/functions.php
Original file line number Diff line number Diff line change
Expand Up @@ -447,13 +447,13 @@ function join_paths(?string $basePath, string ...$paths): string

/**
* Ensure the provided `$app` return an instance of Laravel application or throw an exception.
*
* @internal
*
*
* @internal
*
* @param \Illuminate\Foundation\Application|null $app
* @param string|null $caller
* @return \Illuminate\Foundation\Application
*
*
* @throws \Orchestra\Testbench\Exceptions\ApplicationNotAvailableException
*/
function laravel_or_fail($app, ?string $caller = null): Application
Expand Down

0 comments on commit 896c2e6

Please sign in to comment.