Skip to content

Commit

Permalink
formatting (#367)
Browse files Browse the repository at this point in the history
  • Loading branch information
SonyPradana authored Aug 20, 2024
1 parent 2599ed0 commit caa1f51
Show file tree
Hide file tree
Showing 8 changed files with 10 additions and 12 deletions.
2 changes: 1 addition & 1 deletion src/System/Console/helper.php
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ function any_key($title, callable $callable)
*/
function width(int $min, int $max): int
{
$terminal = new class() {
$terminal = new class {
use TerminalTrait;

public function width(int $min, int $max): int
Expand Down
2 changes: 0 additions & 2 deletions src/System/Http/Request.php
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,6 @@ class Request implements \ArrayAccess, \IteratorAggregate
* @param array<string, string> $cookies
* @param array<string, string> $files
* @param array<string, string> $headers
* @param ?string $rawBody
*/
public function __construct(
string $url,
Expand All @@ -145,7 +144,6 @@ public function __construct(
* @param array<string, string> $cookies
* @param array<string, string> $files
* @param array<string, string> $headers
* @param ?string $rawBody
*
* @return self
*/
Expand Down
2 changes: 1 addition & 1 deletion tests/Cron/BasicCronTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ final class BasicCronTest extends TestCase

protected function setUp(): void
{
$this->logger = new class() implements InterpolateInterface {
$this->logger = new class implements InterpolateInterface {
public function interpolate(string $message, array $context = []): void
{
echo 'works';
Expand Down
2 changes: 1 addition & 1 deletion tests/Cron/CronTimeTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ final class CronTimeTest extends TestCase

protected function setUp(): void
{
$this->logger = new class() implements InterpolateInterface {
$this->logger = new class implements InterpolateInterface {
public function interpolate(string $message, array $context = []): void
{
echo 'works';
Expand Down
2 changes: 1 addition & 1 deletion tests/Cron/ScheduleTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ final class ScheduleTest extends TestCase

protected function setUp(): void
{
$this->logger = new class() implements InterpolateInterface {
$this->logger = new class implements InterpolateInterface {
public function interpolate(string $message, array $context = []): void
{
echo 'works';
Expand Down
4 changes: 2 additions & 2 deletions tests/Integrate/Commands/CronCommandsTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ final class CronCommandsTest extends CommandTest
protected function setUp(): void
{
parent::setUp();
$log = new class() implements InterpolateInterface {
$log = new class implements InterpolateInterface {
/**
* @param array<string, mixed> $context
*/
Expand All @@ -41,7 +41,7 @@ private function maker(string $argv): CronCommand
public function __construct($argv)
{
parent::__construct($argv);
$this->log = new class() implements InterpolateInterface {
$this->log = new class implements InterpolateInterface {
/**
* @param array<string, mixed> $context
*/
Expand Down
6 changes: 3 additions & 3 deletions tests/Integrate/Http/KarnelTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -37,19 +37,19 @@ protected function dispatcher(Request $request): array
'callable' => fn () => new Response('ok', 200),
'parameters' => [],
'middleware' => [
new class() {
new class {
public function handle(Request $request, Closure $next): Response
{
return $next($request);
}
},
new class() {
new class {
public function handle(Request $request, Closure $next): Response
{
return new Response('redirect', 303);
}
},
new class() {
new class {
public function handle(Request $request, Closure $next): Response
{
if ($respone = $next($request)) {
Expand Down
2 changes: 1 addition & 1 deletion tests/Support/MacroTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ final class MacroTest extends TestCase

protected function setUp(): void
{
$this->mock_class = new class() {
$this->mock_class = new class {
use Marco;
};
}
Expand Down

0 comments on commit caa1f51

Please sign in to comment.