Node.js MySQLFixtures 模块
Node.js MySQLFixtures 模块用于管理 MySQL 数据库中的测试夹具。
安装:
npm install mysql-fixtures
使用:
var MySQLFixtures = require('mysql-fixtures');
var config = {
host: 'localhost',
user: 'root',
password: 'root',
database: 'sample'
};
var fixtures = MySQLFixtures.createFixtures(config);
fixtures.create('fixtures/data.yaml', function() {
console.log('完成.');
});
3.35KB
文件大小:
评论区