Skip to content

Commit 5bc4666

Browse files
[6.x] Convert PHPUnit metadata to attributes (#13895)
1 parent 535f31e commit 5bc4666

3 files changed

Lines changed: 10 additions & 10 deletions

File tree

tests/Data/Users/UserQueryBuilderTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -483,7 +483,7 @@ public function values_can_be_plucked()
483483
], User::query()->where('type', 'b')->pluck('name')->all());
484484
}
485485

486-
/** @test **/
486+
#[Test]
487487
public function users_are_found_using_scopes()
488488
{
489489
CustomScope::register();

tests/Fields/BlueprintRepositoryTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -440,7 +440,7 @@ public function find_or_fail_throws_exception_when_blueprint_does_not_exist()
440440
$this->repo->findOrFail('does-not-exist');
441441
}
442442

443-
/** @test */
443+
#[Test]
444444
public function it_gets_a_blueprint_from_split_repository()
445445
{
446446
$repo = (new BlueprintRepository())

tests/Modifiers/DoesntOverlapTest.php

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,15 @@
22

33
namespace Tests\Modifiers;
44

5+
use PHPUnit\Framework\Attributes\Group;
6+
use PHPUnit\Framework\Attributes\Test;
57
use Statamic\Modifiers\Modify;
68
use Tests\TestCase;
79

8-
/**
9-
* @group array
10-
*/
10+
#[Group('array')]
1111
class DoesntOverlapTest extends TestCase
1212
{
13-
/** @test */
13+
#[Test]
1414
public function it_returns_false_if_needle_found_in_array(): void
1515
{
1616
$haystack = ['a', 'b', 'c'];
@@ -19,7 +19,7 @@ public function it_returns_false_if_needle_found_in_array(): void
1919
$this->assertFalse($modified);
2020
}
2121

22-
/** @test */
22+
#[Test]
2323
public function it_returns_true_if_needle_is_not_found_in_array(): void
2424
{
2525
$haystack = ['a', 'b', 'c'];
@@ -28,7 +28,7 @@ public function it_returns_true_if_needle_is_not_found_in_array(): void
2828
$this->assertTrue($modified);
2929
}
3030

31-
/** @test */
31+
#[Test]
3232
public function it_returns_true_if_haystack_is_not_an_array(): void
3333
{
3434
$haystack = 'this is a string';
@@ -37,7 +37,7 @@ public function it_returns_true_if_haystack_is_not_an_array(): void
3737
$this->assertTrue($modified);
3838
}
3939

40-
/** @test */
40+
#[Test]
4141
public function it_returns_false_if_needle_is_an_array_and_is_found_in_array(): void
4242
{
4343
$haystack = ['a', 'b', 'c'];
@@ -46,7 +46,7 @@ public function it_returns_false_if_needle_is_an_array_and_is_found_in_array():
4646
$this->assertFalse($modified);
4747
}
4848

49-
/** @test */
49+
#[Test]
5050
public function it_returns_false_if_needle_is_an_array_and_some_are_not_found_in_array(): void
5151
{
5252
$haystack = ['a', 'b', 'c'];

0 commit comments

Comments
 (0)