Skip to content

Commit

Permalink
Rename *TestCase classes back to *Test when not abstract (#52)
Browse files Browse the repository at this point in the history
* Rename *TestCase classes back to *Test when not abstract
- Were automatically renamed to testcase before when renaming the abstract parent
  • Loading branch information
bram123 authored Aug 29, 2023
1 parent 93b6441 commit 15772d0
Show file tree
Hide file tree
Showing 25 changed files with 53 additions and 24 deletions.
2 changes: 1 addition & 1 deletion phpstan-baseline.neon
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,4 @@ parameters:
-
message: "#^Class DigitalRevolution\\\\AccessorPairConstraint\\\\Tests\\\\Integration\\\\data\\\\TestEnum not found\\.$#"
count: 2
path: tests/Unit/Constraint/ValueProvider/Compound/InstanceProviderTestCase.php
path: tests/Unit/Constraint/ValueProvider/Compound/InstanceProviderTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
/**
* @coversDefaultClass \DigitalRevolution\AccessorPairConstraint\Constraint\ValueProvider\Compound\ArrayProvider
*/
class ArrayProviderTestCase extends AbstractValueProviderTestCase
class ArrayProviderTest extends AbstractValueProviderTestCase
{
/**
* @covers ::__construct
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
/**
* @coversDefaultClass \DigitalRevolution\AccessorPairConstraint\Constraint\ValueProvider\Compound\CallableProvider
*/
class CallableProviderTestCase extends AbstractValueProviderTestCase
class CallableProviderTest extends AbstractValueProviderTestCase
{
/**
* @covers ::getValues
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
/**
* @coversDefaultClass \DigitalRevolution\AccessorPairConstraint\Constraint\ValueProvider\Compound\InstanceProvider
*/
class InstanceProviderTestCase extends AbstractValueProviderTestCase
class InstanceProviderTest extends AbstractValueProviderTestCase
{
/**
* @covers ::__construct
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
<?php
declare(strict_types=1);

namespace DigitalRevolution\AccessorPairConstraint\Tests\Unit\Constraint\ValueProvider\Compound;

use Countable;
use DigitalRevolution\AccessorPairConstraint\Constraint\ValueProvider\Compound\IntersectionProvider;
use DigitalRevolution\AccessorPairConstraint\Tests\Unit\Constraint\ValueProvider\AbstractValueProviderTestCase;
use phpDocumentor\Reflection\Fqsen;
use phpDocumentor\Reflection\Types\Object_;
use stdClass;

/**
* @coversDefaultClass \DigitalRevolution\AccessorPairConstraint\Constraint\ValueProvider\Compound\IntersectionProvider
*/
class IntersectionProviderTest extends AbstractValueProviderTestCase
{
/**
* @covers ::__construct
* @covers ::getValues
*/
public function testGetValues(): void
{
$valueProvider = new IntersectionProvider([new Object_(new Fqsen('\\' . stdClass::class)), new Object_(new Fqsen('\\' . Countable::class))]);

static::assertContainsOnlyInstancesOf(stdClass::class, $valueProvider->getValues());
static::assertContainsOnlyInstancesOf(Countable::class, $valueProvider->getValues());
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
/**
* @coversDefaultClass \DigitalRevolution\AccessorPairConstraint\Constraint\ValueProvider\Compound\IterableProvider
*/
class IterableProviderTestCase extends AbstractValueProviderTestCase
class IterableProviderTest extends AbstractValueProviderTestCase
{
/**
* @covers ::getValues
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
/**
* @coversDefaultClass \DigitalRevolution\AccessorPairConstraint\Constraint\ValueProvider\Compound\ObjectProvider
*/
class ObjectProviderTestCase extends AbstractValueProviderTestCase
class ObjectProviderTest extends AbstractValueProviderTestCase
{
/**
* @covers ::getValues
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
/**
* @coversDefaultClass \DigitalRevolution\AccessorPairConstraint\Constraint\ValueProvider\Keyword\FalseProvider
*/
class FalseProviderTestCase extends AbstractValueProviderTestCase
class FalseProviderTest extends AbstractValueProviderTestCase
{
/**
* @covers ::getValues
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
/**
* @coversDefaultClass \DigitalRevolution\AccessorPairConstraint\Constraint\ValueProvider\Keyword\TrueProvider
*/
class TrueProviderTestCase extends AbstractValueProviderTestCase
class TrueProviderTest extends AbstractValueProviderTestCase
{
/**
* @covers ::getValues
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
/**
* @coversDefaultClass \DigitalRevolution\AccessorPairConstraint\Constraint\ValueProvider\Pseudo\CallableStringProvider
*/
class CallableStringProviderTestCase extends AbstractValueProviderTestCase
class CallableStringProviderTest extends AbstractValueProviderTestCase
{
/**
* @covers ::getValues
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
* @coversDefaultClass \DigitalRevolution\AccessorPairConstraint\Constraint\ValueProvider\Pseudo\ClassStringProvider
* @covers ::__construct
*/
class ClassStringProviderTestCase extends AbstractValueProviderTestCase
class ClassStringProviderTest extends AbstractValueProviderTestCase
{
/**
* @covers ::getValues
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
/**
* @coversDefaultClass \DigitalRevolution\AccessorPairConstraint\Constraint\ValueProvider\Pseudo\HtmlEscapedStringProvider
*/
class HtmlEscapedStringProviderTestCase extends AbstractValueProviderTestCase
class HtmlEscapedStringProviderTest extends AbstractValueProviderTestCase
{
/**
* @covers ::getValues
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
* @coversDefaultClass \DigitalRevolution\AccessorPairConstraint\Constraint\ValueProvider\Pseudo\ListProvider
* @covers ::__construct
*/
class ListProviderTestCase extends AbstractValueProviderTestCase
class ListProviderTest extends AbstractValueProviderTestCase
{
/**
* @covers ::getValues
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
/**
* @coversDefaultClass \DigitalRevolution\AccessorPairConstraint\Constraint\ValueProvider\Pseudo\LiteralStringProvider
*/
class LiteralStringProviderTestCase extends AbstractValueProviderTestCase
class LiteralStringProviderTest extends AbstractValueProviderTestCase
{
/**
* @covers ::getValues
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
* @covers ::__construct
* @uses \DigitalRevolution\AccessorPairConstraint\Constraint\ValueProvider\Scalar\StringProvider
*/
class LowercaseStringProviderTestCase extends AbstractValueProviderTestCase
class LowercaseStringProviderTest extends AbstractValueProviderTestCase
{
/**
* @covers ::getValues
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
* @covers ::__construct
* @uses \DigitalRevolution\AccessorPairConstraint\Constraint\ValueProvider\Scalar\StringProvider
*/
class NonEmptyStringProviderTestCase extends AbstractValueProviderTestCase
class NonEmptyStringProviderTest extends AbstractValueProviderTestCase
{
/**
* @covers ::getValues
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
/**
* @coversDefaultClass \DigitalRevolution\AccessorPairConstraint\Constraint\ValueProvider\Pseudo\NumericStringProvider
*/
class NumericStringProviderTestCase extends AbstractValueProviderTestCase
class NumericStringProviderTest extends AbstractValueProviderTestCase
{
/**
* @covers ::getValues
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
/**
* @coversDefaultClass \DigitalRevolution\AccessorPairConstraint\Constraint\ValueProvider\Pseudo\TraitStringProvider
*/
class TraitStringProviderTestCase extends AbstractValueProviderTestCase
class TraitStringProviderTest extends AbstractValueProviderTestCase
{
/**
* @covers ::getValues
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
/**
* @coversDefaultClass \DigitalRevolution\AccessorPairConstraint\Constraint\ValueProvider\Scalar\BoolProvider
*/
class BoolProviderTestCase extends AbstractValueProviderTestCase
class BoolProviderTest extends AbstractValueProviderTestCase
{
/**
* @covers ::getValues
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
* @coversDefaultClass \DigitalRevolution\AccessorPairConstraint\Constraint\ValueProvider\Scalar\FloatProvider
* @uses \DigitalRevolution\AccessorPairConstraint\Constraint\ValueProvider\Scalar\IntProvider
*/
class FloatProviderTestCase extends AbstractValueProviderTestCase
class FloatProviderTest extends AbstractValueProviderTestCase
{
/**
* @covers ::__construct
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* @coversDefaultClass \DigitalRevolution\AccessorPairConstraint\Constraint\ValueProvider\Scalar\IntProvider
* @covers ::__construct
*/
class IntProviderTestCase extends AbstractValueProviderTestCase
class IntProviderTest extends AbstractValueProviderTestCase
{
/**
* @covers ::getValues
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
/**
* @coversDefaultClass \DigitalRevolution\AccessorPairConstraint\Constraint\ValueProvider\Scalar\StringProvider
*/
class StringProviderTestCase extends AbstractValueProviderTestCase
class StringProviderTest extends AbstractValueProviderTestCase
{
/**
* @covers ::getValues
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
/**
* @coversDefaultClass \DigitalRevolution\AccessorPairConstraint\Constraint\ValueProvider\Special\NullProvider
*/
class NullProviderTestCase extends AbstractValueProviderTestCase
class NullProviderTest extends AbstractValueProviderTestCase
{
/**
* @covers ::getValues
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
/**
* @coversDefaultClass \DigitalRevolution\AccessorPairConstraint\Constraint\ValueProvider\Special\ResourceProvider
*/
class ResourceProviderTestCase extends AbstractValueProviderTestCase
class ResourceProviderTest extends AbstractValueProviderTestCase
{
/**
* @covers ::getValues
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
/**
* @coversDefaultClass \DigitalRevolution\AccessorPairConstraint\Constraint\ValueProvider\ValueProviderList
*/
class ValueProviderListTestCase extends AbstractValueProviderTestCase
class ValueProviderListTest extends AbstractValueProviderTestCase
{
/**
* @covers ::__construct
Expand Down

0 comments on commit 15772d0

Please sign in to comment.