Sha256: 1a6b8c90ed2c49f2c95ee453bfcf0fa8767418fe2d1c7b7454d35574e9d8840b
Contents?: true
Size: 1.76 KB
Versions: 2
Compression:
Stored size: 1.76 KB
Contents
$:.unshift File.join(File.dirname(__FILE__), "..", "..", "lib") require 'spec' require 'buildmaster' require 'buildmaster/cotta' require 'buildmaster/cotta/in_memory_system' module BuildMaster context 'CvsDriverTest' do setup do @system = InMemorySystem.new @cotta = Cotta.new(@system) @working = @cotta.dir('working') end teardown do @system = nil @cotta = nil @working = nil end specify 'load_CvsInfo' do folder = @cotta.dir('tmp') folder.mkdirs root = ':ext:wolfdancer@cvsserver.com:/cvs/root' repository = 'xpe' folder.file('ROOT').save(root) folder.file('Repository').save(repository) cvs = CvsInfo.load(folder) cvs.root.should_equal root cvs.repository.should_equal repository end specify 'checkout' do client = CvsDriver.new(CvsInfo.new('root', 'module'), @working) client.checkout @system.executed_commands.size.should_equal 1 @system.executed_commands[0].should_equal 'cvs -d root co -d working module' end specify 'update' do log = '' client = CvsDriver.new(CvsInfo.new('root', 'module'), @working) client.update @system.executed_commands.size.should_equal 1 @system.executed_commands[0].should_equal 'cvs -d root update working' client.update('-PAd') @system.executed_commands.size.should_equal 2 @system.executed_commands[1].should_equal 'cvs -d root update -PAd working' end specify 'command' do log = '' client = CvsDriver.new(CvsInfo.new('root', 'module'), @working) client.command('command -option argument') @system.executed_commands.size.should_equal 1 @system.executed_commands[0].should_equal 'cvs -d root command -option argument working' end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
BuildMaster-0.9.0 | test/buildmaster/tc_cvs_driver.rb |
BuildMaster-0.9.1 | test/buildmaster/tc_cvs_driver.rb |