Skip to content

Releases: ikvasnica/phpstan-clean-test

v0.4

23 Aug 19:35
Compare
Choose a tag to compare
  • Add support for PHP 8.1 and later
  • Drop support for older PHP versions
  • Add support for PHPStan 1.10 and later

v0.3.1

09 Aug 12:48
Compare
Choose a tag to compare
  • Do NOT apply StaticAssertOverThisAndStaticRule to "assert" methods outside PHPUnit TestCase

v0.3

12 Feb 00:35
eb86811
Compare
Choose a tag to compare
  • Drop support for PHP 7.1 (requires PHP >=7.2)
  • Drop support for PHPStan 0.11 (requires PHPStan >=0.12.0)

v0.2

12 Feb 00:24
2eb3514
Compare
Choose a tag to compare

Rules

DisallowSetupAndConstructorRule: Neither of methods __construct nor setUp can be declared in a unit test.

AssertSameOverAssertEqualsRule: Calling assertEquals in tests is forbidden in favor of assertSame.

StaticAssertOverThisAndStaticRule: Calling $this->assert*, self::assert* or static::assert* in tests is forbidden in favor of PHPUnit\Framework\Assert::assert*.

NoNullableArgumentRule: Nullable arguments and arguments with no type passed to test methods from data providers are forbidden.

v0.1.1

27 Jan 01:45
881f9f6
Compare
Choose a tag to compare

Bugfix

  • Allow a lower version of Nette/Utils as a dependency (3.0 instead of 3.1)

v0.1

27 Jan 01:23
373c4a5
Compare
Choose a tag to compare

Rules

  • UnitExtendsFromTestCaseRule - This rule forces you to extend only from allowed classes in unit tests (default: PHPUnit\Framework\TestCase).