mirror of
				https://github.com/elyby/accounts.git
				synced 2025-05-31 14:11:46 +05:30 
			
		
		
		
	Fix PHPStan errors
This commit is contained in:
		@@ -4,16 +4,18 @@ namespace api\tests\functional\mojang;
 | 
			
		||||
use api\tests\FunctionalTester;
 | 
			
		||||
use Codeception\Example;
 | 
			
		||||
 | 
			
		||||
class UsernameToUuidCest {
 | 
			
		||||
final class UsernameToUuidCest {
 | 
			
		||||
 | 
			
		||||
    public static function endpoints(): array {
 | 
			
		||||
        return [
 | 
			
		||||
            ['/api/mojang/profiles'],
 | 
			
		||||
            ['/api/mojang/services/minecraft/profile/lookup/name'],
 | 
			
		||||
        ];
 | 
			
		||||
    /**
 | 
			
		||||
     * @return iterable<array{string}>
 | 
			
		||||
     */
 | 
			
		||||
    public static function endpoints(): iterable {
 | 
			
		||||
        yield ['/api/mojang/profiles'];
 | 
			
		||||
        yield ['/api/mojang/services/minecraft/profile/lookup/name'];
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * @param Example<array{string}> $url
 | 
			
		||||
     * @dataProvider endpoints
 | 
			
		||||
     */
 | 
			
		||||
    public function getUuidByUsername(FunctionalTester $I, Example $url): void {
 | 
			
		||||
@@ -28,6 +30,7 @@ class UsernameToUuidCest {
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * @param Example<array{string}> $url
 | 
			
		||||
     * @dataProvider endpoints
 | 
			
		||||
     */
 | 
			
		||||
    public function getUuidByUsernameAtMoment(FunctionalTester $I, Example $url): void {
 | 
			
		||||
@@ -42,6 +45,7 @@ class UsernameToUuidCest {
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * @param Example<array{string}> $url
 | 
			
		||||
     * @dataProvider endpoints
 | 
			
		||||
     */
 | 
			
		||||
    public function getUuidByUsernameAtWrongMoment(FunctionalTester $I, Example $url): void {
 | 
			
		||||
@@ -52,6 +56,7 @@ class UsernameToUuidCest {
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * @param Example<array{string}> $url
 | 
			
		||||
     * @dataProvider endpoints
 | 
			
		||||
     */
 | 
			
		||||
    public function getUuidByUsernameWithoutMoment(FunctionalTester $I, Example $url): void {
 | 
			
		||||
@@ -62,6 +67,7 @@ class UsernameToUuidCest {
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * @param Example<array{string}> $url
 | 
			
		||||
     * @dataProvider endpoints
 | 
			
		||||
     */
 | 
			
		||||
    public function getUuidByWrongUsername(FunctionalTester $I, Example $url): void {
 | 
			
		||||
@@ -72,6 +78,7 @@ class UsernameToUuidCest {
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * @param Example<array{string}> $url
 | 
			
		||||
     * @dataProvider endpoints
 | 
			
		||||
     */
 | 
			
		||||
    public function getUuidForDeletedAccount(FunctionalTester $I, Example $url): void {
 | 
			
		||||
@@ -82,6 +89,7 @@ class UsernameToUuidCest {
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * @param Example<array{string}> $url
 | 
			
		||||
     * @dataProvider endpoints
 | 
			
		||||
     */
 | 
			
		||||
    public function nonPassedUsername(FunctionalTester $I, Example $url): void {
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user