public function setUp() { parent::setUp(); $application = new Application(); $application->add(new UpAllCommand(null, $this->parametersFromYmlFile)); $this->command = $application->find('up-all'); $this->commandTester = new CommandTester($this->command); }
public function setUp() { parent::setUp(); $companies = $this->db->selectCollection('Company'); $companies->upsert([], ['name' => 'Bob', 'address' => ['streetFirstLine' => 'Lena Gardens']]); $migrations = $this->db->selectCollection('MongrateMigrations'); $migrations->upsert(['className' => 'UpdateAddressStructure'], ['$set' => ['isApplied' => true]]); }
public function setUp() { parent::setUp(); $this->expectedFile = 'resources/examples/CreatedByTests_' . date('Ymd') . '/Migration.php'; $this->duplicateFile = 'resources/examples/DuplicateTest_' . date('Ymd') . '/Migration.php'; $this->deleteTestFiles(); $application = new Application(); $application->add(new GenerateMigrationCommand(null, $this->parametersFromYmlFile)); $this->command = $application->find('generate-migration'); $this->commandTester = new CommandTester($this->command); }
public function setUp() { parent::setUp(); $collection = $this->db->selectCollection('Company'); $collection->upsert([], ['name' => 'Amy', 'address' => [['streetFirstLine' => 'Lena Gardens'], ['streetFirstLine' => 'Marlow Place']]]); }