Skip to content

Commit 47d3d1c

Browse files
committed
Rename test methods
1 parent bf2caf0 commit 47d3d1c

File tree

84 files changed

+384
-855
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

84 files changed

+384
-855
lines changed

tests/Integration/AppCheckTest.php

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66

77
use Kreait\Firebase\Contract\AppCheck;
88
use Kreait\Firebase\Tests\IntegrationTestCase;
9-
use PHPUnit\Framework\Attributes\Test;
109

1110
/**
1211
* @internal
@@ -26,24 +25,21 @@ protected function setUp(): void
2625
$this->appCheck = self::$factory->createAppCheck();
2726
}
2827

29-
#[Test]
30-
public function createTokenWithDefaultTtl(): void
28+
public function testCreateTokenWithDefaultTtl(): void
3129
{
3230
$token = $this->appCheck->createToken(self::$appId);
3331

3432
$this->assertSame('3600s', $token->ttl);
3533
}
3634

37-
#[Test]
38-
public function createTokenWithCustomTtl(): void
35+
public function testCreateTokenWithCustomTtl(): void
3936
{
4037
$token = $this->appCheck->createToken(self::$appId, ['ttl' => 1800]);
4138

4239
$this->assertSame('1800s', $token->ttl);
4340
}
4441

45-
#[Test]
46-
public function verifyToken(): void
42+
public function testVerifyToken(): void
4743
{
4844
$token = $this->appCheck->createToken(self::$appId);
4945

tests/Integration/Auth/CustomTokenViaGoogleCredentialsTest.php

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616
use Lcobucci\JWT\Encoding\JoseEncoder;
1717
use Lcobucci\JWT\Token\Parser;
1818
use Lcobucci\JWT\UnencryptedToken;
19-
use PHPUnit\Framework\Attributes\Test;
2019

2120
/**
2221
* @internal
@@ -44,8 +43,7 @@ protected function setUp(): void
4443
$this->auth = self::$factory->createAuth();
4544
}
4645

47-
#[Test]
48-
public function createCustomToken(): void
46+
public function testCreateCustomToken(): void
4947
{
5048
$token = $this->generator->createCustomToken($this->uid, ['a-claim' => 'a-value']);
5149

@@ -54,8 +52,7 @@ public function createCustomToken(): void
5452
$this->assertSame($this->uid, $check->firebaseUserId());
5553
}
5654

57-
#[Test]
58-
public function aGeneratedCustomTokenCanBeParsed(): void
55+
public function testAGeneratedCustomTokenCanBeParsed(): void
5956
{
6057
$token = $this->generator->createCustomToken($this->uid, ['a-claim' => 'a-value']);
6158

tests/Integration/Auth/UserQueryTest.php

Lines changed: 6 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88
use Kreait\Firebase\Auth\UserRecord;
99
use Kreait\Firebase\Contract\Auth;
1010
use Kreait\Firebase\Tests\IntegrationTestCase;
11-
use PHPUnit\Framework\Attributes\Test;
1211

1312
use function random_int;
1413

@@ -27,8 +26,7 @@ protected function setUp(): void
2726
$this->ensureNumberOfUsers(2);
2827
}
2928

30-
#[Test]
31-
public function itReturnsResultsInAscendingOrder(): void
29+
public function testItReturnsResultsInAscendingOrder(): void
3230
{
3331
$query = UserQuery::all()
3432
->withLimit(2)
@@ -46,8 +44,7 @@ public function itReturnsResultsInAscendingOrder(): void
4644
$this->assertGreaterThan($first->metadata->createdAt, $second->metadata->createdAt);
4745
}
4846

49-
#[Test]
50-
public function itReturnsResultsInDescendingOrder(): void
47+
public function testItReturnsResultsInDescendingOrder(): void
5148
{
5249
$query = UserQuery::all()
5350
->withLimit(2)
@@ -65,16 +62,14 @@ public function itReturnsResultsInDescendingOrder(): void
6562
$this->assertLessThan($first->metadata->createdAt, $second->metadata->createdAt);
6663
}
6764

68-
#[Test]
69-
public function limit(): void
65+
public function testLimit(): void
7066
{
7167
$result = $this->auth->queryUsers(UserQuery::all()->withLimit(1));
7268

7369
$this->assertCount(1, $result);
7470
}
7571

76-
#[Test]
77-
public function filterByUid(): void
72+
public function testFilterByUid(): void
7873
{
7974
$user = $this->createUserWithEmailAndPassword();
8075

@@ -95,8 +90,7 @@ public function filterByUid(): void
9590
}
9691
}
9792

98-
#[Test]
99-
public function filterByEmail(): void
93+
public function testFilterByEmail(): void
10094
{
10195
$user = $this->createUserWithEmailAndPassword();
10296

@@ -117,8 +111,7 @@ public function filterByEmail(): void
117111
}
118112
}
119113

120-
#[Test]
121-
public function filterByPhoneNumber(): void
114+
public function testFilterByPhoneNumber(): void
122115
{
123116
$user = $this->auth->createUser([
124117
'phoneNumber' => '+49'.random_int(90_000_000_000, 99_999_999_999),

0 commit comments

Comments
 (0)