Sha256: abd62fb61e0961550ae54e92174d3446028a7d546544ff7e6288d79fb513724b

Contents?: true

Size: 823 Bytes

Versions: 14

Compression:

Stored size: 823 Bytes

Contents

require File.expand_path(File.dirname(__FILE__) + '/../example_helper')

describe Astrails::Safe::Svndump do
  def def_config
    {
      :options => "OPTS",
      :repo_path => "bar/baz"
    }
  end

  def svndump(id = :foo, config = def_config)
    Astrails::Safe::Svndump.new(id, Astrails::Safe::Config::Node.new(nil, config))
  end

  before(:each) do
    stub(Time).now.stub!.strftime {"NOW"}
  end

  after(:each) { Astrails::Safe::TmpFile.cleanup }

  describe :backup do
    before(:each) do
      @svn = svndump
    end

    {
      :id => "foo",
      :kind => "svndump",
      :extension => ".svn",
      :filename => "svndump-foo.NOW",
      :command => "svnadmin dump OPTS bar/baz",
    }.each do |k, v|
      it "should set #{k} to #{v}" do
        @svn.backup.send(k).should == v
      end
    end

  end
end

Version data entries

14 entries across 14 versions & 3 rubygems

Version Path
astrails-safe-0.1.10 examples/unit/svndump_example.rb
astrails-safe-0.1.7 examples/unit/svndump_example.rb
astrails-safe-0.1.8 examples/unit/svndump_example.rb
astrails-safe-0.1.9 examples/unit/svndump_example.rb
astrails-safe-0.2.0 examples/unit/svndump_example.rb
astrails-safe-0.2.1 examples/unit/svndump_example.rb
astrails-safe-0.2.2 examples/unit/svndump_example.rb
astrails-safe-0.2.3 examples/unit/svndump_example.rb
bostonlogic-safe-0.3.0 examples/unit/svndump_example.rb
astrails-safe-0.2.7 examples/unit/svndump_example.rb
astrails-safe-0.2.6 examples/unit/svndump_example.rb
astrails-safe-0.2.5 examples/unit/svndump_example.rb
webbynode-safe-0.2.5 examples/unit/svndump_example.rb
astrails-safe-0.2.4 examples/unit/svndump_example.rb