Skip to content

Commit

Permalink
#53 - Change DROP TABLE to use via method
Browse files Browse the repository at this point in the history
  • Loading branch information
Jeckerson committed Feb 6, 2020
1 parent cc4631f commit f22013f
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion tests/Integration/MySQL/ColumnTypesTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ public function testColumnDefinition(string $columnName, array $definition, arra
'config' => self::$generateConfig,
'tableName' => $tableName,
]);
$this->db->query('DROP TABLE ' . $tableName);
$this->db->dropTable($tableName);
Migrations::run([
'migrationsDir' => $migrationsDir,
'config' => self::$generateConfig,
Expand Down
6 changes: 3 additions & 3 deletions tests/Integration/MySQL/TimestampedVersionTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ public function testSingleVersion(): void
]);

Migrations::generate($options);
$this->db->query('DROP TABLE `' . $tableName . '`');
$this->db->dropTable($tableName);
Migrations::run($options);

$this->assertTrue($this->db->tableExists($tableName));
Expand Down Expand Up @@ -90,8 +90,8 @@ public function testSeveralVersions(): void
/**
* Drop tables and run migrations
*/
$this->db->query('DROP TABLE `' . $tableName1 . '`');
$this->db->query('DROP TABLE `' . $tableName2 . '`');
$this->db->dropTable($tableName1);
$this->db->dropTable($tableName2);
Migrations::run($options);

$this->assertTrue($this->db->tableExists($tableName1));
Expand Down
2 changes: 1 addition & 1 deletion tests/Integration/PostgreSQL/ColumnTypesTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ public function testColumnDefinition(string $columnName, array $definition, arra
'config' => self::$generateConfig,
'tableName' => $tableName,
]);
$this->db->query('DROP TABLE ' . $tableName);
$this->db->dropTable($tableName);
Migrations::run([
'migrationsDir' => $migrationsDir,
'config' => self::$generateConfig,
Expand Down
2 changes: 1 addition & 1 deletion tests/Integration/PostgreSQL/IssuesTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ public function testIssue1(): void
'config' => self::$generateConfig,
'tableName' => $tableName,
]);
$this->db->query('DROP TABLE ' . $tableName);
$this->db->dropTable($tableName);
Migrations::run([
'migrationsDir' => $migrationsDir,
'config' => self::$generateConfig,
Expand Down

0 comments on commit f22013f

Please sign in to comment.