-
-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Mior Muhammad Zaki <[email protected]>
- Loading branch information
Showing
18 changed files
with
328 additions
and
36 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,6 +3,7 @@ name: coveralls | |
on: | ||
push: | ||
pull_request: | ||
workflow_dispatch: | ||
|
||
jobs: | ||
tests: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,6 +3,7 @@ name: tests | |
on: | ||
push: | ||
pull_request: | ||
workflow_dispatch: | ||
schedule: | ||
- cron: '0 0 * * *' | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
<?php | ||
|
||
namespace Orchestra\Testbench\Dusk\Attributes; | ||
|
||
use Attribute; | ||
use Closure; | ||
use Orchestra\Testbench\Contracts\Attributes\Actionable as ActionableContract; | ||
|
||
#[Attribute(Attribute::TARGET_CLASS | Attribute::TARGET_METHOD)] | ||
final class BeforeServing implements ActionableContract | ||
{ | ||
/** | ||
* The target method. | ||
* | ||
* @var string | ||
*/ | ||
public $method; | ||
|
||
/** | ||
* Construct a new attribute. | ||
* | ||
* @param string $method | ||
*/ | ||
public function __construct(string $method) | ||
{ | ||
$this->method = $method; | ||
} | ||
|
||
/** | ||
* Handle the attribute. | ||
* | ||
* @param \Illuminate\Foundation\Application $app | ||
* @param \Closure(string, array<int, mixed>):void $action | ||
* @return string | ||
*/ | ||
public function handle($app, Closure $action): string | ||
{ | ||
return $this->method; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
<?php | ||
|
||
namespace Orchestra\Testbench\Dusk\Attributes; | ||
|
||
use Attribute; | ||
use Closure; | ||
use Orchestra\Testbench\Contracts\Attributes\Actionable as ActionableContract; | ||
|
||
#[Attribute(Attribute::TARGET_CLASS | Attribute::TARGET_METHOD)] | ||
final class RestartServer implements ActionableContract | ||
{ | ||
/** | ||
* Handle the attribute. | ||
* | ||
* @param \Illuminate\Foundation\Application $app | ||
* @param \Closure(string, array<int, mixed>):void $action | ||
*/ | ||
public function handle($app, Closure $action): void | ||
{ | ||
\call_user_func($action, 'reloadServing', []); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.