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

Commit c42f6b7e by Mick Hansen

Merge pull request #2665 from mbroadst/fix-schema-test-move-drop-schema

fix schema test and move dropSchema to AbstractDialect
2 parents 28922c73 8e7789e7
......@@ -28,6 +28,13 @@ module.exports = (function() {
},
/*
Returns a query for dropping a schema
*/
dropSchema: function(tableName, options) {
return this.dropTableQuery(tableName, options);
},
/*
Returns a query for creating a table.
Parameters:
- tableName: Name of the new table.
......
......@@ -13,10 +13,6 @@ module.exports = (function() {
return Utils._.template(query)({});
},
dropSchema: function(tableName, options) {
return this.dropTableQuery(tableName, options);
},
showSchemasQuery: function() {
return 'SHOW TABLES';
},
......
......@@ -24,10 +24,6 @@ module.exports = (function() {
return Utils._.template(query)({});
},
dropSchema: function(tableName, options) {
return this.dropTableQuery(tableName, options);
},
showSchemasQuery: function() {
return "SELECT name FROM `sqlite_master` WHERE type='table' and name!='sqlite_sequence';";
},
......
......@@ -8,11 +8,11 @@ var chai = require('chai')
chai.config.includeStack = true;
describe(Support.getTestDialectTeaser('Schema'), function () {
before(function() {
beforeEach(function() {
return this.sequelize.createSchema('testschema');
});
after(function() {
afterEach(function() {
return this.sequelize.dropSchema('testschema');
});
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!