不要怂,就是干,撸起袖子干!

Commit 953d2047 by tngraessler
1 parent 631c2c07
Showing with 4 additions and 0 deletions
......@@ -113,6 +113,10 @@ if (Support.dialectIsMySQL()) {
{
arguments: ['myTable', {title: 'VARCHAR(255)', name: 'VARCHAR(255)', otherId: 'INTEGER REFERENCES `otherTable` (`id`) ON DELETE CASCADE ON UPDATE NO ACTION'}],
expectation: "CREATE TABLE IF NOT EXISTS `myTable` (`title` VARCHAR(255), `name` VARCHAR(255), `otherId` INTEGER, FOREIGN KEY (`otherId`) REFERENCES `otherTable` (`id`) ON DELETE CASCADE ON UPDATE NO ACTION) ENGINE=InnoDB;"
},
{
arguments: ['myTable', {title: { type: 'VARCHAR(255)', unique: 'title_name' }, name: { type: 'VARCHAR(255)', unique: 'title_name' }}],
expectation: "CREATE TABLE IF NOT EXISTS `myTable` (`title` VARCHAR(255), `name` VARCHAR(255), UNIQUE uniq_myTable_title_name (`title`, `name`)) ENGINE=InnoDB;"
}
],
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!