specinfra 0.3.0 → 0.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ab2e8748dcfdbefe6f652b466245be213a341e1d
4
- data.tar.gz: ba10e9c3b7bb0fa4c60405c3796f90ecff26de63
3
+ metadata.gz: 62817ce531572a444a7ddb053f70273d9edc65b4
4
+ data.tar.gz: 76782c7e4aa98e1773fa93183fd51811bd125095
5
5
  SHA512:
6
- metadata.gz: 05356147ab0a1dc6a8af87651345bdda63aced1c355a00f1918ec1827dc9184ef915ce517f4dd9305b210d7d3063cf0fa2657a1ed6cf3b7491d6487abc7ba196
7
- data.tar.gz: cecb53c968761730618456c7773f340f30e37106b52894f38e0dda336ab2706be42c02f5451c83dbf3e1396ddfaac575532c891e38921ed670c1bdaa87f7e700
6
+ metadata.gz: b331580ad78a8975549f9d76c5a5dd16505f3fc18ca43d7376a644d11c169d33a9cd2a1dfea4a320fbcf83fd95f37a34af698a104fb667734c51806454bfaf01
7
+ data.tar.gz: 33405e454fbe91cddf69b16f151e346787a13448c1404de05b920cacf017c878588a2fe9b63fcbd9780a5e5a49048cb83900e0d5b4d15da6d5ead8b7bf02c5f0
@@ -42,7 +42,13 @@ module SpecInfra
42
42
  end
43
43
 
44
44
  def copy_file(from, to)
45
- raise NotImplementedError.new
45
+ scp = SpecInfra.configuration.scp
46
+ begin
47
+ scp.upload!(from, to)
48
+ rescue => e
49
+ return false
50
+ end
51
+ true
46
52
  end
47
53
 
48
54
  private
@@ -1,3 +1,3 @@
1
1
  module Specinfra
2
- VERSION = "0.3.0"
2
+ VERSION = "0.3.1"
3
3
  end
data/lib/specinfra.rb CHANGED
@@ -20,6 +20,7 @@ if defined?(RSpec)
20
20
  c.add_setting :os, :default => nil
21
21
  c.add_setting :host, :default => nil
22
22
  c.add_setting :ssh, :default => nil
23
+ c.add_setting :scp, :default => nil
23
24
  c.add_setting :sudo_password, :default => nil
24
25
  c.add_setting :winrm, :default => nil
25
26
  SpecInfra.configuration.defaults.each { |k, v| c.add_setting k, :default => v }
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: specinfra
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 0.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gosuke Miyashita