Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Possibility to rebuild database after testrun #106

Open
KeKs0r opened this issue Oct 28, 2013 · 1 comment
Open

Possibility to rebuild database after testrun #106

KeKs0r opened this issue Oct 28, 2013 · 1 comment
Labels
feature move-to-fixtures-repository May need to be moved to https://github.com/liip/LiipTestFixturesBundle

Comments

@KeKs0r
Copy link

KeKs0r commented Oct 28, 2013

Hi,

I am just starting with this bundle and it might be possible that I am trying to use it wrong. As I understood I should loadFixtures() before I run a test against the DB. But 80% of my DB Tests, don't modify my database. Thats why I am searching for a way to build my database once on the start of my testsuite and then only reset it after it was modified.

Is this also possible with this bundle or do I need to use something different?

@dbu dbu added feature and removed bug labels Aug 4, 2014
@alexislefebvre
Copy link
Collaborator

@KeKs0r You can load the fixtures in setUp():

public function setUp()
{
    $this->loadFixtures(array(
        'Liip\FunctionalTestBundle\Tests\App\DataFixtures\ORM\LoadUserData',
    ));
}

If then you enable cache_sqlite_db tests will be faster.

@alexislefebvre alexislefebvre added the move-to-fixtures-repository May need to be moved to https://github.com/liip/LiipTestFixturesBundle label May 8, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature move-to-fixtures-repository May need to be moved to https://github.com/liip/LiipTestFixturesBundle
Projects
None yet
Development

No branches or pull requests

3 participants