diff --git a/phpstan.src.baseline.neon b/phpstan.src.baseline.neon index e574d4ab..99aa4355 100644 --- a/phpstan.src.baseline.neon +++ b/phpstan.src.baseline.neon @@ -20,6 +20,21 @@ parameters: count: 1 path: src/External/Dto/Option.php + - + message: "#^Generic type Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\HasMany\\ in PHPDoc tag @return does not specify all template types of class Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\HasMany\\: TRelatedModel, TDeclaringModel$#" + count: 1 + path: src/Interfaces/Wallet.php + + - + message: "#^Generic type Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\HasMany\\ in PHPDoc tag @return does not specify all template types of class Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\HasMany\\: TRelatedModel, TDeclaringModel$#" + count: 2 + path: src/Interfaces/Wallet.php + + - + message: "#^Generic type Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\MorphMany\\ in PHPDoc tag @return does not specify all template types of class Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\MorphMany\\: TRelatedModel, TDeclaringModel$#" + count: 1 + path: src/Interfaces/Wallet.php + - message: "#^Parameter \\#3 \\$payableId of class Bavix\\\\Wallet\\\\Internal\\\\Dto\\\\TransactionDto constructor expects int\\|string, mixed given\\.$#" count: 1 @@ -186,7 +201,12 @@ parameters: path: src/Internal/Service/StorageService.php - - message: "#^Method Bavix\\\\Wallet\\\\Models\\\\Transaction\\:\\:wallet\\(\\) should return Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\BelongsTo\\ but returns Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\BelongsTo\\\\.$#" + message: "#^Method Bavix\\\\Wallet\\\\Models\\\\Transaction\\:\\:payable\\(\\) should return Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\MorphTo\\ but returns Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\MorphTo\\\\.$#" + count: 1 + path: src/Models/Transaction.php + + - + message: "#^Method Bavix\\\\Wallet\\\\Models\\\\Transaction\\:\\:wallet\\(\\) should return Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\BelongsTo\\ but returns Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\BelongsTo\\\\.$#" count: 1 path: src/Models/Transaction.php @@ -206,22 +226,22 @@ parameters: path: src/Models/Transaction.php - - message: "#^Method Bavix\\\\Wallet\\\\Models\\\\Transfer\\:\\:deposit\\(\\) should return Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\BelongsTo\\ but returns Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\BelongsTo\\\\.$#" + message: "#^Method Bavix\\\\Wallet\\\\Models\\\\Transfer\\:\\:deposit\\(\\) should return Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\BelongsTo\\ but returns Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\BelongsTo\\\\.$#" count: 1 path: src/Models/Transfer.php - - message: "#^Method Bavix\\\\Wallet\\\\Models\\\\Transfer\\:\\:from\\(\\) should return Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\BelongsTo\\ but returns Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\BelongsTo\\\\.$#" + message: "#^Method Bavix\\\\Wallet\\\\Models\\\\Transfer\\:\\:from\\(\\) should return Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\BelongsTo\\ but returns Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\BelongsTo\\\\.$#" count: 1 path: src/Models/Transfer.php - - message: "#^Method Bavix\\\\Wallet\\\\Models\\\\Transfer\\:\\:to\\(\\) should return Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\BelongsTo\\ but returns Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\BelongsTo\\\\.$#" + message: "#^Method Bavix\\\\Wallet\\\\Models\\\\Transfer\\:\\:to\\(\\) should return Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\BelongsTo\\ but returns Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\BelongsTo\\\\.$#" count: 1 path: src/Models/Transfer.php - - message: "#^Method Bavix\\\\Wallet\\\\Models\\\\Transfer\\:\\:withdraw\\(\\) should return Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\BelongsTo\\ but returns Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\BelongsTo\\\\.$#" + message: "#^Method Bavix\\\\Wallet\\\\Models\\\\Transfer\\:\\:withdraw\\(\\) should return Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\BelongsTo\\ but returns Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\BelongsTo\\\\.$#" count: 1 path: src/Models/Transfer.php @@ -250,11 +270,36 @@ parameters: count: 2 path: src/Models/Wallet.php + - + message: "#^Generic type Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\HasMany\\ in PHPDoc tag @return does not specify all template types of class Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\HasMany\\: TRelatedModel, TDeclaringModel$#" + count: 2 + path: src/Models/Wallet.php + + - + message: "#^Generic type Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\HasMany\\ in PHPDoc tag @return does not specify all template types of class Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\HasMany\\: TRelatedModel, TDeclaringModel$#" + count: 4 + path: src/Models/Wallet.php + + - + message: "#^Generic type Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\MorphMany\\ in PHPDoc tag @return does not specify all template types of class Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\MorphMany\\: TRelatedModel, TDeclaringModel$#" + count: 2 + path: src/Models/Wallet.php + + - + message: "#^Generic type Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\MorphOne\\ in PHPDoc tag @return does not specify all template types of class Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\MorphOne\\: TRelatedModel, TDeclaringModel$#" + count: 2 + path: src/Models/Wallet.php + - message: "#^Method Bavix\\\\Wallet\\\\Models\\\\Wallet\\:\\:getCurrencyAttribute\\(\\) should return string but returns mixed\\.$#" count: 1 path: src/Models/Wallet.php + - + message: "#^Method Bavix\\\\Wallet\\\\Models\\\\Wallet\\:\\:holder\\(\\) should return Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\MorphTo\\ but returns Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\MorphTo\\\\.$#" + count: 1 + path: src/Models/Wallet.php + - message: "#^Parameter \\#1 \\$amount of method Bavix\\\\Wallet\\\\Interfaces\\\\Wallet\\:\\:forceWithdraw\\(\\) expects int\\|non\\-empty\\-string, int\\|string given\\.$#" count: 2 diff --git a/phpstan.tests.baseline.neon b/phpstan.tests.baseline.neon index 1ee7bcf5..3c6c3f9a 100644 --- a/phpstan.tests.baseline.neon +++ b/phpstan.tests.baseline.neon @@ -1,5 +1,10 @@ parameters: ignoreErrors: + - + message: "#^Generic type Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\HasMany\\ in PHPDoc tag @return does not specify all template types of class Illuminate\\\\Database\\\\Eloquent\\\\Relations\\\\HasMany\\: TRelatedModel, TDeclaringModel$#" + count: 1 + path: tests/Infra/Models/Item.php + - message: "#^Parameter \\#2 \\$currency of class Bavix\\\\Wallet\\\\Test\\\\Infra\\\\Values\\\\Money constructor expects string, mixed given\\.$#" count: 1 @@ -35,6 +40,21 @@ parameters: count: 1 path: tests/Infra/TestCase.php + - + message: "#^Access to an undefined property Illuminate\\\\Database\\\\Eloquent\\\\Model\\:\\:\\$balanceInt\\.$#" + count: 1 + path: tests/Units/Domain/MultiWalletTest.php + + - + message: "#^Access to an undefined property Illuminate\\\\Database\\\\Eloquent\\\\Model\\:\\:\\$slug\\.$#" + count: 1 + path: tests/Units/Domain/MultiWalletTest.php + + - + message: "#^Access to an undefined property Illuminate\\\\Database\\\\Eloquent\\\\Model\\:\\:\\$uuid\\.$#" + count: 1 + path: tests/Units/Domain/MultiWalletTest.php + - message: "#^Parameter \\#1 \\$number of method Bavix\\\\Wallet\\\\Internal\\\\Service\\\\MathServiceInterface\\:\\:abs\\(\\) expects float\\|int\\|non\\-empty\\-string, string given\\.$#" count: 1