Skip to content

Commit 9bc0f80

Browse files
Use constant instead of number for purgeMode parameter
1 parent 9bcebcf commit 9bc0f80

1 file changed

Lines changed: 3 additions & 5 deletions

File tree

tests/Test/WebTestCaseConfigMysqlTest.php

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ public function testLoadFixturesAndExcludeFromPurge(): void
196196
);
197197

198198
$this->setExcludedDoctrineTables(['liip_user']);
199-
$this->loadFixtures([], false, null, 'doctrine', 2);
199+
$this->loadFixtures([], false, null, 'doctrine', ORMPurger::PURGE_MODE_TRUNCATE);
200200

201201
// The exclusion from purge worked, the user table is still alive and well.
202202
$this->assertSame(
@@ -237,8 +237,7 @@ public function testLoadFixturesAndPurge(): void
237237
$users
238238
);
239239

240-
// 1 → ORMPurger::PURGE_MODE_DELETE
241-
$this->loadFixtures([], false, null, 'doctrine', 1);
240+
$this->loadFixtures([], false, null, 'doctrine', ORMPurger::PURGE_MODE_DELETE);
242241

243242
// The purge worked: there is no user.
244243
$users = $em->getRepository('LiipFunctionalTestBundle:User')
@@ -263,8 +262,7 @@ public function testLoadFixturesAndPurge(): void
263262
$users
264263
);
265264

266-
// 2 → ORMPurger::PURGE_MODE_TRUNCATE
267-
$this->loadFixtures([], false, null, 'doctrine', 2);
265+
$this->loadFixtures([], false, null, 'doctrine', ORMPurger::PURGE_MODE_TRUNCATE);
268266

269267
// The purge worked: there is no user.
270268
$this->assertSame(

0 commit comments

Comments
 (0)