Skip to content

Commit 1b6cf58

Browse files
committed
Rename tables to avoid pg related illegal table name
1 parent 6501890 commit 1b6cf58

File tree

4 files changed

+9
-7
lines changed

4 files changed

+9
-7
lines changed

tests/Tests/Models/AbstractFetchEager/AbstractRemoveControl.php renamed to tests/Tests/Models/AbstractFetchEager/AbstractRemoteControl.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,12 @@
1010

1111
/**
1212
* @ORM\Entity()
13+
* @ORM\Table(name="abstract_fetch_eager_remote_control")
1314
* @ORM\InheritanceType("SINGLE_TABLE")
1415
* @ORM\DiscriminatorColumn(name="type", type="string")
1516
* @ORM\DiscriminatorMap({"mobile"="MobileRemoteControl"})
1617
*/
17-
abstract class AbstractRemoveControl
18+
abstract class AbstractRemoteControl
1819
{
1920
/**
2021
* @ORM\Id

tests/Tests/Models/AbstractFetchEager/MobileRemoteControl.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,6 @@
99
/**
1010
* @ORM\Entity()
1111
*/
12-
class MobileRemoteControl extends AbstractRemoveControl
12+
class MobileRemoteControl extends AbstractRemoteControl
1313
{
1414
}

tests/Tests/Models/AbstractFetchEager/User.php

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88

99
/**
1010
* @ORM\Entity()
11+
* @ORM\Table(name="abstract_fetch_eager_user")
1112
*/
1213
class User
1314
{
@@ -21,14 +22,14 @@ class User
2122
public $id;
2223

2324
/**
24-
* @ORM\ManyToOne(targetEntity="AbstractRemoveControl", inversedBy="users")
25+
* @ORM\ManyToOne(targetEntity="AbstractRemoteControl", inversedBy="users")
2526
* @ORM\JoinColumn(nullable=false)
2627
*
27-
* @var AbstractRemoveControl
28+
* @var AbstractRemoteControl
2829
*/
2930
public $remoteControl;
3031

31-
public function __construct(AbstractRemoveControl $control)
32+
public function __construct(AbstractRemoteControl $control)
3233
{
3334
$this->remoteControl = $control;
3435
}

tests/Tests/ORM/Functional/AbstractFetchEagerTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
namespace Doctrine\Tests\ORM\Functional;
66

7-
use Doctrine\Tests\Models\AbstractFetchEager\AbstractRemoveControl;
7+
use Doctrine\Tests\Models\AbstractFetchEager\AbstractRemoteControl;
88
use Doctrine\Tests\Models\AbstractFetchEager\MobileRemoteControl;
99
use Doctrine\Tests\Models\AbstractFetchEager\User;
1010
use Doctrine\Tests\OrmFunctionalTestCase;
@@ -14,7 +14,7 @@ final class AbstractFetchEagerTest extends OrmFunctionalTestCase
1414
public function testWithAbstractFetchEager(): void
1515
{
1616
$this->createSchemaForModels(
17-
AbstractRemoveControl::class,
17+
AbstractRemoteControl::class,
1818
User::class
1919
);
2020

0 commit comments

Comments
 (0)