Sha256: 8b4e3078329ea312e30e3a0b8a4ae1910a7fa9cd1f2adf0e94e67ae155fc4641

Contents?: true

Size: 911 Bytes

Versions: 85

Compression:

Stored size: 911 Bytes

Contents

require 'utils'
require 'capistrano/recipes/deploy/scm/none'

class DeploySCMNoneTest < Test::Unit::TestCase
  class TestSCM < Capistrano::Deploy::SCM::None
    default_command 'none'
  end

  def setup
    @config = {}
    def @config.exists?(name); key?(name); end
    @source = TestSCM.new(@config)
  end

  def test_the_truth
    assert true
  end

  def test_checkout_on_linux
    Capistrano::Deploy::LocalDependency.stubs(:on_windows?).returns(false)
    @config[:repository] = '.'
    rev = ''
    dest = '/var/www'
    assert_equal "cp -R . /var/www", @source.checkout(rev, dest)
  end

  def test_checkout_on_windows
    Capistrano::Deploy::LocalDependency.stubs(:on_windows?).returns(true)
    @config[:repository] = '.'
    rev = ''
    dest = 'c:/Documents and settings/admin/tmp'
    assert_equal "xcopy . \"c:/Documents and settings/admin/tmp\" /S/I/Y/Q/E", @source.checkout(rev, dest)
  end

end

Version data entries

85 entries across 85 versions & 10 rubygems

Version Path
capistrano-2.15.11 test/deploy/scm/none_test.rb
capistrano-2.15.10 test/deploy/scm/none_test.rb
capistrano-2.15.9 test/deploy/scm/none_test.rb
wulffeld-capistrano-2.5.8.3 test/deploy/scm/none_test.rb
capistrano-2.15.8 test/deploy/scm/none_test.rb
capistrano-2.5.22 test/deploy/scm/none_test.rb
capistrano-2.15.7 test/deploy/scm/none_test.rb
capistrano-2.15.6 test/deploy/scm/none_test.rb
dan-capistrano-2.5.6 test/deploy/scm/none_test.rb
fotonauts-capistrano-2.5.2 test/deploy/scm/none_test.rb
sneakin-capistrano-2.5.5 test/deploy/scm/none_test.rb
thoughtbot-capistrano-2.5.5 test/deploy/scm/none_test.rb
thoughtbot-capistrano-2.5.6 test/deploy/scm/none_test.rb
capistrano-2.15.5 test/deploy/scm/none_test.rb
minmb-capistrano-2.15.4 test/deploy/scm/none_test.rb
capistrano-2.15.4 test/deploy/scm/none_test.rb
capistrano-2.15.3 test/deploy/scm/none_test.rb
capistrano-2.15.2 test/deploy/scm/none_test.rb
capistrano-2.15.0 test/deploy/scm/none_test.rb
capistrano-2.15.1 test/deploy/scm/none_test.rb