From 165d0b52651fee9e1adf89b4cf27dd6e5baf0381 Mon Sep 17 00:00:00 2001 From: Greg Bowler Date: Tue, 14 Jan 2025 15:40:23 +0000 Subject: [PATCH] wip: tweak test layout --- test/phpunit/Migration/EntityDetectorTest.php | 8 ++++---- test/phpunit/Migration/SchemaGeneratorTest.php | 2 +- .../SimpleEntitiesAndNonEntities/NotAnEntity.php | 6 ------ .../NestedNamespace/OrderEntity.php | 4 ++-- .../SimpleEntitiesAndNonEntities/NotAnEntity.php | 6 ++++++ .../SimpleEntitiesAndNonEntities/PersonEntity.php | 2 +- 6 files changed, 14 insertions(+), 14 deletions(-) delete mode 100644 test/phpunit/TestProject/01-EntityDetectorTest/SimpleEntitiesAndNonEntities/NotAnEntity.php rename test/phpunit/TestProject/{01-EntityDetectorTest => EntityDetectorTest}/SimpleEntitiesAndNonEntities/NestedNamespace/OrderEntity.php (54%) create mode 100644 test/phpunit/TestProject/EntityDetectorTest/SimpleEntitiesAndNonEntities/NotAnEntity.php rename test/phpunit/TestProject/{01-EntityDetectorTest => EntityDetectorTest}/SimpleEntitiesAndNonEntities/PersonEntity.php (72%) diff --git a/test/phpunit/Migration/EntityDetectorTest.php b/test/phpunit/Migration/EntityDetectorTest.php index 5453bf9..96277b1 100644 --- a/test/phpunit/Migration/EntityDetectorTest.php +++ b/test/phpunit/Migration/EntityDetectorTest.php @@ -2,9 +2,9 @@ namespace Gt\Orm\Test\Migration; use Gt\Orm\Migration\EntityDetector; -use Gt\Orm\Test\TestProjectRoot\SimpleEntitiesAndNonEntities\NestedNamespace\OrderEntity; -use Gt\Orm\Test\TestProjectRoot\SimpleEntitiesAndNonEntities\NotAnEntity; -use Gt\Orm\Test\TestProjectRoot\SimpleEntitiesAndNonEntities\PersonEntity; +use Gt\Orm\Test\TestProject\EntityDetectorTest\SimpleEntitiesAndNonEntities\NestedNamespace\OrderEntity; +use Gt\Orm\Test\TestProject\EntityDetectorTest\SimpleEntitiesAndNonEntities\NotAnEntity; +use Gt\Orm\Test\TestProject\EntityDetectorTest\SimpleEntitiesAndNonEntities\PersonEntity; use PHPUnit\Framework\TestCase; class EntityDetectorTest extends TestCase { @@ -16,7 +16,7 @@ public function testGetEntityClassList_noFiles():void { } public function testGetEntityClassList():void { - $dir = "test/phpunit/TestProject/01-EntityDetectorTest"; + $dir = "test/phpunit/TestProject/EntityDetectorTest"; $sut = new EntityDetector(); $detected = $sut->getEntityClassList($dir); self::assertCount(2, $detected); diff --git a/test/phpunit/Migration/SchemaGeneratorTest.php b/test/phpunit/Migration/SchemaGeneratorTest.php index c48efe1..8645314 100644 --- a/test/phpunit/Migration/SchemaGeneratorTest.php +++ b/test/phpunit/Migration/SchemaGeneratorTest.php @@ -3,7 +3,7 @@ use DateTime; use Gt\Orm\Migration\SchemaGenerator; -use Gt\Orm\Test\TestProjectRoot\SimpleEntitiesAndNonEntities\PersonEntity; +use Gt\Orm\Test\TestProject\EntityDetectorTest\SimpleEntitiesAndNonEntities\PersonEntity; use PHPUnit\Framework\TestCase; class SchemaGeneratorTest extends TestCase { diff --git a/test/phpunit/TestProject/01-EntityDetectorTest/SimpleEntitiesAndNonEntities/NotAnEntity.php b/test/phpunit/TestProject/01-EntityDetectorTest/SimpleEntitiesAndNonEntities/NotAnEntity.php deleted file mode 100644 index 7ce2507..0000000 --- a/test/phpunit/TestProject/01-EntityDetectorTest/SimpleEntitiesAndNonEntities/NotAnEntity.php +++ /dev/null @@ -1,6 +0,0 @@ -