Skip to content

Commit 58c0654

Browse files
committed
chore: execute pint on codebase
1 parent ba3bb17 commit 58c0654

17 files changed

+48
-27
lines changed

src/Illuminate/Testing/PendingCommand.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -340,9 +340,10 @@ public function expectsPromptsOutro(string $message)
340340
*
341341
* @param array<int, string|array<int, string>>|Collection<int, string|array<int, string>> $headers
342342
* @param array<int, array<int, string>>|Collection<int, array<int, string>>|null $rows
343-
* @return $this
344343
*
345344
* @phpstan-param ($rows is null ? list<list<string>>|Collection<int, list<string>> : list<string|list<string>>|Collection<int, string|list<string>>) $headers
345+
*
346+
* @return $this
346347
*/
347348
public function expectsPromptsTable(array|Collection $headers, array|Collection|null $rows)
348349
{

src/Illuminate/Validation/InvokableValidationRule.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,8 @@ protected function __construct(ValidationRule|InvokableRule $invokable)
6868
public static function make($invokable)
6969
{
7070
if ($invokable->implicit ?? false) {
71-
return new class($invokable) extends InvokableValidationRule implements ImplicitRule {
71+
return new class($invokable) extends InvokableValidationRule implements ImplicitRule
72+
{
7273
};
7374
}
7475

tests/Bus/BusPendingBatchTest.php

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,8 @@ public function test_batch_is_deleted_from_storage_if_exception_thrown_during_ba
7171

7272
$container = new Container;
7373

74-
$job = new class {
74+
$job = new class
75+
{
7576
};
7677

7778
$pendingBatch = new PendingBatch($container, new Collection([$job]));
@@ -226,7 +227,8 @@ public function test_batch_before_event_is_called()
226227

227228
public function test_it_throws_exception_if_batched_job_is_not_batchable(): void
228229
{
229-
$nonBatchableJob = new class {
230+
$nonBatchableJob = new class
231+
{
230232
};
231233

232234
$this->expectException(RuntimeException::class);
@@ -242,7 +244,8 @@ public function test_it_throws_an_exception_if_batched_job_contains_batch_with_n
242244
new PendingBatch(
243245
$container,
244246
new Collection(
245-
[new PendingBatch($container, new Collection([new BatchableJob, new class {
247+
[new PendingBatch($container, new Collection([new BatchableJob, new class
248+
{
246249
}]))]
247250
)
248251
);

tests/Container/ContainerTest.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1094,9 +1094,7 @@ class WildcardConcrete implements WildcardOnlyInterface
10941094
{
10951095
}
10961096

1097-
/*
1098-
* The order of these attributes matters because we want to ensure we only fallback to '*' when there's no more specific environment.
1099-
*/
1097+
// The order of these attributes matters because we want to ensure we only fallback to '*' when there's no more specific environment.
11001098
#[Bind(FallbackConcrete::class)]
11011099
#[Bind(ProdConcrete::class, environments: 'prod')]
11021100
interface WildcardAndProdInterface

tests/Database/DatabaseAbstractSchemaGrammarTest.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,8 @@ protected function tearDown(): void
1717
public function testCreateDatabase()
1818
{
1919
$connection = m::mock(Connection::class);
20-
$grammar = new class($connection) extends Grammar {
20+
$grammar = new class($connection) extends Grammar
21+
{
2122
};
2223

2324
$this->assertSame('create database "foo"', $grammar->compileCreateDatabase('foo'));
@@ -26,7 +27,8 @@ public function testCreateDatabase()
2627
public function testDropDatabaseIfExists()
2728
{
2829
$connection = m::mock(Connection::class);
29-
$grammar = new class($connection) extends Grammar {
30+
$grammar = new class($connection) extends Grammar
31+
{
3032
};
3133

3234
$this->assertSame('drop database if exists "foo"', $grammar->compileDropDatabaseIfExists('foo'));

tests/Database/DatabaseEloquentInverseRelationTest.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -288,7 +288,8 @@ public function testOnlyHydratesInverseRelationOnModels()
288288
[],
289289
new HasInverseRelationRelatedStub(),
290290
'foo',
291-
new class() {
291+
new class()
292+
{
292293
},
293294
new HasInverseRelationRelatedStub(),
294295
]);

tests/Encryption/EncrypterTest.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -248,10 +248,12 @@ public static function provideTamperedData()
248248

249249
return [
250250
[['iv' => ['value_in_array'], 'value' => '', 'mac' => '']],
251-
[['iv' => new class() {
251+
[['iv' => new class()
252+
{
252253
}, 'value' => '', 'mac' => '']],
253254
[['iv' => $validIv, 'value' => ['value_in_array'], 'mac' => '']],
254-
[['iv' => $validIv, 'value' => new class() {
255+
[['iv' => $validIv, 'value' => new class()
256+
{
255257
}, 'mac' => '']],
256258
[['iv' => $validIv, 'value' => '', 'mac' => ['value_in_array']]],
257259
[['iv' => $validIv, 'value' => '', 'mac' => null]],

tests/Http/JsonResourceTest.php

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,8 @@ class JsonResourceTest extends TestCase
1212
{
1313
public function testJsonResourceNullAttributes()
1414
{
15-
$model = new class extends Model {
15+
$model = new class extends Model
16+
{
1617
};
1718

1819
$model->setAttribute('relation_sum_column', null);
@@ -32,7 +33,8 @@ public function testJsonResourceNullAttributes()
3233

3334
public function testJsonResourceToJsonSucceedsWithPriorErrors(): void
3435
{
35-
$model = new class extends Model {
36+
$model = new class extends Model
37+
{
3638
};
3739

3840
$resource = m::mock(JsonResource::class, ['resource' => $model])
@@ -49,7 +51,8 @@ public function testJsonResourceToJsonSucceedsWithPriorErrors(): void
4951

5052
public function testJsonResourceToPrettyPrint(): void
5153
{
52-
$model = new class extends Model {
54+
$model = new class extends Model
55+
{
5356
};
5457

5558
$resource = m::mock(JsonResource::class, ['resource' => $model])

tests/Integration/Database/EloquentModelEncryptedDirtyTest.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44

55
use Illuminate\Database\Eloquent\Casts\AsEncryptedArrayObject;
66
use Illuminate\Database\Eloquent\Model;
7-
use Illuminate\Support\Collection;
87
use Orchestra\Testbench\TestCase;
98

109
class EloquentModelEncryptedDirtyTest extends TestCase

tests/Pagination/CursorPaginatorLoadMorphCountTest.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,8 @@ public function testCollectionLoadMorphCountCanChainOnThePaginator()
1919
$items = m::mock(Collection::class);
2020
$items->shouldReceive('loadMorphCount')->once()->with('parentable', $relations);
2121

22-
$p = (new class extends AbstractCursorPaginator {
22+
$p = (new class extends AbstractCursorPaginator
23+
{
2324
})->setCollection($items);
2425

2526
$this->assertSame($p, $p->loadMorphCount('parentable', $relations));

0 commit comments

Comments
 (0)