spec/flydata/command/sync_spec.rb in flydata-0.1.7 vs spec/flydata/command/sync_spec.rb in flydata-0.1.8
- old
+ new
@@ -382,33 +382,33 @@
end
end
end
module Mysql
- describe MysqlDumpGenerator do
+ describe MysqlDumpGeneratorMasterData do
let(:stdout) { double(:stdout) }
let(:stderr) { double(:stderr) }
let(:status) { double(:status) }
let(:file_path) { File.join('/tmp', "flydata_sync_spec_mysqldump_#{Time.now.to_i}") }
let(:default_conf) { {
'host' => 'localhost', 'port' => 3306, 'username' => 'admin',
'password' => 'pass', 'database' => 'dev', 'tables' => 'users,groups',
} }
- let(:default_dump_generator) { MysqlDumpGenerator.new(default_conf) }
+ let(:default_dump_generator) { MysqlDumpGeneratorMasterData.new(default_conf) }
describe '#initialize' do
context 'with password' do
subject { default_dump_generator.instance_variable_get(:@dump_cmd) }
it { should eq('mysqldump --protocol=tcp -h localhost -P 3306 -uadmin -ppass --skip-lock-tables ' +
- '--single-transaction --flush-logs --hex-blob --master-data=2 dev users groups') }
+ '--single-transaction --hex-blob --flush-logs --master-data=2 dev users groups') }
end
context 'without password' do
let (:dump_generator) do
- MysqlDumpGenerator.new(default_conf.merge({'password' => ''}))
+ MysqlDumpGeneratorMasterData.new(default_conf.merge({'password' => ''}))
end
subject { dump_generator.instance_variable_get(:@dump_cmd) }
it { should eq('mysqldump --protocol=tcp -h localhost -P 3306 -uadmin --skip-lock-tables ' +
- '--single-transaction --flush-logs --hex-blob --master-data=2 dev users groups') }
+ '--single-transaction --hex-blob --flush-logs --master-data=2 dev users groups') }
end
end
describe '#dump' do
context 'when exit status is not 0' do