Improved API tests and added test for short URLs creation

This commit is contained in:
Alejandro Celaya
2019-01-30 18:28:07 +01:00
parent d61f5faf59
commit 4c46aaead8
6 changed files with 176 additions and 45 deletions

View File

@@ -5,6 +5,7 @@ namespace ShlinkioTest\Shlink\Common;
use Doctrine\Common\DataFixtures\Executor\ORMExecutor;
use Doctrine\Common\DataFixtures\Loader;
use Doctrine\Common\DataFixtures\Purger\ORMPurger;
use Doctrine\ORM\EntityManagerInterface;
use Symfony\Component\Process\Process;
use function file_exists;
@@ -38,7 +39,7 @@ class TestHelper
$loader->loadFromDirectory($path);
}
$executor = new ORMExecutor($em);
$executor->execute($loader->getFixtures(), true);
$executor = new ORMExecutor($em, new ORMPurger());
$executor->execute($loader->getFixtures());
}
}