yii\test\FixtureTrait::unloadFixtures PHP Méthode

unloadFixtures() public méthode

This method will call [[Fixture::unload()]] for every fixture object.
public unloadFixtures ( Fixture[] $fixtures = null )
$fixtures Fixture[] the fixtures to be loaded. If this parameter is not specified, the return value of [[getFixtures()]] will be used.
    public function unloadFixtures($fixtures = null)
    {
        if ($fixtures === null) {
            $fixtures = $this->getFixtures();
        }
        /* @var $fixture Fixture */
        foreach ($fixtures as $fixture) {
            $fixture->beforeUnload();
        }
        $fixtures = array_reverse($fixtures);
        foreach ($fixtures as $fixture) {
            $fixture->unload();
        }
        foreach ($fixtures as $fixture) {
            $fixture->afterUnload();
        }
    }