heirloom 0.4.0 → 0.4.1rc1
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.
- data/CHANGELOG +4 -0
- data/lib/heirloom/archive/downloader.rb +8 -6
- data/lib/heirloom/archive/verifier.rb +11 -0
- data/lib/heirloom/archive.rb +4 -0
- data/lib/heirloom/cli/authorize.rb +5 -3
- data/lib/heirloom/cli/build.rb +1 -3
- data/lib/heirloom/cli/destroy.rb +3 -0
- data/lib/heirloom/cli/download.rb +7 -4
- data/lib/heirloom/cli/list.rb +2 -0
- data/lib/heirloom/cli/shared.rb +14 -0
- data/lib/heirloom/cli/show.rb +3 -1
- data/lib/heirloom/cli/update.rb +2 -0
- data/lib/heirloom/cli.rb +1 -0
- data/lib/heirloom/version.rb +1 -1
- data/spec/archive/downloader_spec.rb +33 -82
- data/spec/cli/authorize_spec.rb +6 -0
- data/spec/cli/destroy_spec.rb +6 -0
- data/spec/cli/download_spec.rb +10 -7
- data/spec/cli/list_spec.rb +6 -0
- data/spec/cli/shared_spec.rb +27 -0
- data/spec/cli/show_spec.rb +6 -0
- data/spec/cli/update_spec.rb +6 -0
- metadata +16 -19
data/CHANGELOG
CHANGED
@@ -11,13 +11,13 @@ module Heirloom
|
|
11
11
|
|
12
12
|
def download(args)
|
13
13
|
region = args[:region]
|
14
|
+
base_prefix = args[:base_prefix]
|
14
15
|
|
15
16
|
s3_downloader = Downloader::S3.new :config => @config,
|
16
17
|
:logger => @logger,
|
17
18
|
:region => region
|
18
19
|
|
19
|
-
bucket =
|
20
|
-
key = reader.get_key :region => region
|
20
|
+
bucket = get_bucket :region => region, :base_prefix => base_prefix
|
21
21
|
|
22
22
|
@logger.info "Downloading s3://#{bucket}/#{key} from #{region}."
|
23
23
|
|
@@ -37,10 +37,12 @@ module Heirloom
|
|
37
37
|
|
38
38
|
private
|
39
39
|
|
40
|
-
def
|
41
|
-
|
42
|
-
|
43
|
-
|
40
|
+
def get_bucket(args)
|
41
|
+
"#{args[:base_prefix]}-#{args[:region]}"
|
42
|
+
end
|
43
|
+
|
44
|
+
def key
|
45
|
+
"#{@name}/#{@id}.tar.gz"
|
44
46
|
end
|
45
47
|
|
46
48
|
end
|
data/lib/heirloom/archive.rb
CHANGED
@@ -1,5 +1,3 @@
|
|
1
|
-
require 'json'
|
2
|
-
|
3
1
|
module Heirloom
|
4
2
|
module CLI
|
5
3
|
class Authorize
|
@@ -11,10 +9,14 @@ module Heirloom
|
|
11
9
|
@logger = HeirloomLogger.new :log_level => @opts[:level]
|
12
10
|
@config = load_config :logger => @logger,
|
13
11
|
:opts => @opts
|
12
|
+
|
14
13
|
exit 1 unless valid_options? :provided => @opts,
|
15
14
|
:required => [:accounts,
|
16
15
|
:name, :id],
|
17
16
|
:logger => @logger
|
17
|
+
|
18
|
+
ensure_domain_exists :name => @opts[:name], :config => @config
|
19
|
+
|
18
20
|
@archive = Archive.new :name => @opts[:name],
|
19
21
|
:id => @opts[:id],
|
20
22
|
:config => @config
|
@@ -43,7 +45,7 @@ EOS
|
|
43
45
|
opt :accounts, "AWS Account(s) email to authorize. Can be specified multiple times.", :type => :string,
|
44
46
|
:multi => true
|
45
47
|
opt :help, "Display Help"
|
46
|
-
opt :id, "
|
48
|
+
opt :id, "ID of the archive to authorize.", :type => :string
|
47
49
|
opt :key, "AWS Access Key", :type => :string
|
48
50
|
opt :level, "Log level [debug|info|warn|error].", :type => :string,
|
49
51
|
:default => 'info'
|
data/lib/heirloom/cli/build.rb
CHANGED
@@ -1,5 +1,3 @@
|
|
1
|
-
require 'json'
|
2
|
-
|
3
1
|
module Heirloom
|
4
2
|
module CLI
|
5
3
|
class Build
|
@@ -73,7 +71,7 @@ Can be specified multiple times.", :type => :string,
|
|
73
71
|
opt :key, "AWS Access Key ID", :type => :string
|
74
72
|
opt :git, "Read git commit information from directory and set as archive attributes."
|
75
73
|
opt :help, "Display Help"
|
76
|
-
opt :id, "
|
74
|
+
opt :id, "ID for archive (when -g specified, assumed to be GIT sha).", :type => :string
|
77
75
|
opt :level, "Log level [debug|info|warn|error].", :type => :string,
|
78
76
|
:default => 'info'
|
79
77
|
opt :name, "Name of archive.", :type => :string
|
data/lib/heirloom/cli/destroy.rb
CHANGED
@@ -13,6 +13,9 @@ module Heirloom
|
|
13
13
|
exit 1 unless valid_options? :provided => @opts,
|
14
14
|
:required => [:name, :id],
|
15
15
|
:logger => @logger
|
16
|
+
|
17
|
+
ensure_domain_exists :name => @opts[:name], :config => @config
|
18
|
+
|
16
19
|
@name = @opts[:name]
|
17
20
|
@id = @opts[:id]
|
18
21
|
@archive = Archive.new :name => @name,
|
@@ -11,7 +11,8 @@ module Heirloom
|
|
11
11
|
:opts => @opts
|
12
12
|
|
13
13
|
exit 1 unless valid_options? :provided => @opts,
|
14
|
-
:required => [:
|
14
|
+
:required => [:base_prefix, :name,
|
15
|
+
:id, :output],
|
15
16
|
:logger => @logger
|
16
17
|
|
17
18
|
@archive = Archive.new :name => @opts[:name],
|
@@ -20,8 +21,9 @@ module Heirloom
|
|
20
21
|
end
|
21
22
|
|
22
23
|
def download
|
23
|
-
@archive.download :output
|
24
|
-
:region
|
24
|
+
@archive.download :output => @opts[:output],
|
25
|
+
:region => @opts[:region],
|
26
|
+
:base_prefix => @opts[:base_prefix]
|
25
27
|
end
|
26
28
|
|
27
29
|
private
|
@@ -39,7 +41,8 @@ heirloom download -n NAME -i ID -r REGION -o OUTPUT_FILE
|
|
39
41
|
|
40
42
|
EOS
|
41
43
|
opt :help, "Display Help"
|
42
|
-
opt :
|
44
|
+
opt :base_prefix, "Base prefix of the archive to download.", :type => :string
|
45
|
+
opt :id, "ID of the archive to download.", :type => :string
|
43
46
|
opt :key, "AWS Access Key ID", :type => :string
|
44
47
|
opt :name, "Name of archive.", :type => :string
|
45
48
|
opt :level, "Log level [debug|info|warn|error].", :type => :string,
|
data/lib/heirloom/cli/list.rb
CHANGED
data/lib/heirloom/cli/shared.rb
CHANGED
@@ -32,6 +32,20 @@ module Heirloom
|
|
32
32
|
config
|
33
33
|
end
|
34
34
|
|
35
|
+
def ensure_domain_exists(args)
|
36
|
+
config = args[:config]
|
37
|
+
name = args[:name]
|
38
|
+
logger = config.logger
|
39
|
+
|
40
|
+
archive = Archive.new :name => name,
|
41
|
+
:config => config
|
42
|
+
|
43
|
+
unless archive.domain_exists?
|
44
|
+
logger.error "Heirloom domain does not exist."
|
45
|
+
exit 1
|
46
|
+
end
|
47
|
+
end
|
48
|
+
|
35
49
|
end
|
36
50
|
end
|
37
51
|
end
|
data/lib/heirloom/cli/show.rb
CHANGED
@@ -14,6 +14,8 @@ module Heirloom
|
|
14
14
|
:required => [:name],
|
15
15
|
:logger => @logger
|
16
16
|
|
17
|
+
ensure_domain_exists :name => @opts[:name], :config => @config
|
18
|
+
|
17
19
|
id = @opts[:id] ? @opts[:id] : latest_id
|
18
20
|
@archive = Archive.new :name => @opts[:name],
|
19
21
|
:config => @config,
|
@@ -51,7 +53,7 @@ EOS
|
|
51
53
|
opt :level, "Log level [debug|info|warn|error].", :type => :string,
|
52
54
|
:default => 'info'
|
53
55
|
opt :name, "Name of archive.", :type => :string
|
54
|
-
opt :id, "
|
56
|
+
opt :id, "ID of the archive to display.", :type => :string
|
55
57
|
opt :secret, "AWS Secret Access Key", :type => :string
|
56
58
|
end
|
57
59
|
end
|
data/lib/heirloom/cli/update.rb
CHANGED
data/lib/heirloom/cli.rb
CHANGED
data/lib/heirloom/version.rb
CHANGED
@@ -2,92 +2,43 @@ require 'spec_helper'
|
|
2
2
|
|
3
3
|
describe Heirloom do
|
4
4
|
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
5
|
+
before do
|
6
|
+
@config_mock = double 'config'
|
7
|
+
@logger_stub = double 'logger', :info => true, :debug => true
|
8
|
+
@config_mock.should_receive(:logger).and_return(@logger_stub)
|
9
|
+
@downloader = Heirloom::Downloader.new :config => @config_mock,
|
10
|
+
:name => 'tim',
|
11
|
+
:id => '123'
|
12
|
+
@s3_downloader_mock = mock 's3 downloader'
|
13
|
+
Heirloom::Downloader::S3.should_receive(:new).
|
14
|
+
with(:config => @config_mock,
|
15
|
+
:logger => @logger_stub,
|
16
|
+
:region => 'us-west-1').
|
17
|
+
and_return @s3_downloader_mock
|
18
|
+
@s3_downloader_mock.should_receive(:download_file).
|
19
|
+
with(:bucket => 'bucket-us-west-1',
|
20
|
+
:key => 'tim/123.tar.gz').
|
21
|
+
and_return 'filename'
|
22
|
+
@file_mock = mock 'file'
|
23
|
+
end
|
24
|
+
|
25
|
+
context "with base_prefix specified" do
|
26
|
+
it "should download to the current path if output is not specified" do
|
27
|
+
File.should_receive(:open).with('./123.tar.gz', 'w').
|
28
|
+
and_return @file_mock
|
29
|
+
|
30
|
+
@downloader.download :region => 'us-west-1',
|
31
|
+
:base_prefix => 'bucket'
|
12
32
|
end
|
13
33
|
|
14
|
-
it "should download
|
15
|
-
s3_downloader_mock = mock 's3 downloader'
|
16
|
-
Heirloom::Downloader::S3.should_receive(:new).
|
17
|
-
with(:config => @config_mock,
|
18
|
-
:logger => @logger_mock,
|
19
|
-
:region => 'us-west-1').
|
20
|
-
and_return s3_downloader_mock
|
21
|
-
reader_mock = mock 'reader'
|
22
|
-
@downloader.should_receive(:reader).
|
23
|
-
exactly(2).times.
|
24
|
-
and_return reader_mock
|
25
|
-
reader_mock.should_receive(:get_bucket).
|
26
|
-
with(:region => 'us-west-1').
|
27
|
-
and_return 'bucket-us-west-1'
|
28
|
-
reader_mock.should_receive(:get_key).
|
29
|
-
with(:region => 'us-west-1').
|
30
|
-
and_return 'key'
|
31
|
-
|
32
|
-
@logger_mock.should_receive(:info).
|
33
|
-
with "Downloading s3://bucket-us-west-1/key from us-west-1."
|
34
|
-
|
35
|
-
s3_downloader_mock.should_receive(:download_file).
|
36
|
-
with(:bucket => 'bucket-us-west-1',
|
37
|
-
:key => 'key').
|
38
|
-
and_return 'filename'
|
39
|
-
|
40
|
-
@logger_mock.should_receive(:info).
|
41
|
-
with "Writing file to /tmp/file."
|
42
|
-
|
43
|
-
file_mock = mock 'file'
|
44
|
-
|
34
|
+
it "should download arhcive to specified output" do
|
45
35
|
File.should_receive(:open).with('/tmp/file', 'w').
|
46
|
-
and_return file_mock
|
47
|
-
|
48
|
-
@logger_mock.should_receive(:info).with "Download complete."
|
49
|
-
|
50
|
-
@downloader.download(:output => '/tmp/file',
|
51
|
-
:region => 'us-west-1')
|
52
|
-
end
|
53
|
-
|
54
|
-
it "should download the archive to the current path if output is unspecficief" do
|
55
|
-
s3_downloader_mock = mock 's3 downloader'
|
56
|
-
Heirloom::Downloader::S3.should_receive(:new).
|
57
|
-
with(:config => @config_mock,
|
58
|
-
:logger => @logger_mock,
|
59
|
-
:region => 'us-west-1').
|
60
|
-
and_return s3_downloader_mock
|
61
|
-
reader_mock = mock 'reader'
|
62
|
-
@downloader.should_receive(:reader).
|
63
|
-
exactly(2).times.
|
64
|
-
and_return reader_mock
|
65
|
-
reader_mock.should_receive(:get_bucket).
|
66
|
-
with(:region => 'us-west-1').
|
67
|
-
and_return 'bucket-us-west-1'
|
68
|
-
reader_mock.should_receive(:get_key).
|
69
|
-
with(:region => 'us-west-1').
|
70
|
-
and_return 'key'
|
71
|
-
|
72
|
-
@logger_mock.should_receive(:info).
|
73
|
-
with "Downloading s3://bucket-us-west-1/key from us-west-1."
|
74
|
-
|
75
|
-
s3_downloader_mock.should_receive(:download_file).
|
76
|
-
with(:bucket => 'bucket-us-west-1',
|
77
|
-
:key => 'key').
|
78
|
-
and_return 'filename'
|
79
|
-
|
80
|
-
@logger_mock.should_receive(:info).
|
81
|
-
with "Writing file to ./key."
|
82
|
-
|
83
|
-
file_mock = mock 'file'
|
84
|
-
|
85
|
-
File.should_receive(:open).with('./key', 'w').
|
86
|
-
and_return file_mock
|
87
|
-
|
88
|
-
@logger_mock.should_receive(:info).with "Download complete."
|
36
|
+
and_return @file_mock
|
89
37
|
|
90
|
-
@downloader.download
|
38
|
+
@downloader.download :output => '/tmp/file',
|
39
|
+
:region => 'us-west-1',
|
40
|
+
:base_prefix => 'bucket'
|
91
41
|
end
|
42
|
+
end
|
92
43
|
|
93
44
|
end
|
data/spec/cli/authorize_spec.rb
CHANGED
@@ -11,6 +11,7 @@ describe Heirloom do
|
|
11
11
|
@logger_mock = mock 'logger'
|
12
12
|
@config_mock = mock 'config'
|
13
13
|
@archive_mock = mock 'archive'
|
14
|
+
@config_mock.stub :logger => @logger_mock
|
14
15
|
Trollop.stub(:options).and_return options
|
15
16
|
Heirloom::HeirloomLogger.should_receive(:new).with(:log_level => 'info').
|
16
17
|
and_return @logger_mock
|
@@ -18,11 +19,16 @@ describe Heirloom do
|
|
18
19
|
with(:logger => @logger_mock,
|
19
20
|
:opts => options).
|
20
21
|
and_return @config_mock
|
22
|
+
Heirloom::Archive.should_receive(:new).
|
23
|
+
with(:name => 'archive_name',
|
24
|
+
:config => @config_mock).
|
25
|
+
and_return @archive_mock
|
21
26
|
Heirloom::Archive.should_receive(:new).
|
22
27
|
with(:id => '1.0.0',
|
23
28
|
:name => 'archive_name',
|
24
29
|
:config => @config_mock).
|
25
30
|
and_return @archive_mock
|
31
|
+
@archive_mock.should_receive(:domain_exists?).and_return true
|
26
32
|
@cli_authorize = Heirloom::CLI::Authorize.new
|
27
33
|
end
|
28
34
|
|
data/spec/cli/destroy_spec.rb
CHANGED
@@ -10,6 +10,7 @@ describe Heirloom do
|
|
10
10
|
@logger_mock = mock 'logger'
|
11
11
|
@config_mock = mock 'config'
|
12
12
|
@archive_mock = mock 'archive'
|
13
|
+
@config_mock.stub :logger => @logger_mock
|
13
14
|
Trollop.stub(:options).and_return options
|
14
15
|
Heirloom::HeirloomLogger.should_receive(:new).with(:log_level => 'info').
|
15
16
|
and_return @logger_mock
|
@@ -17,11 +18,16 @@ describe Heirloom do
|
|
17
18
|
with(:logger => @logger_mock,
|
18
19
|
:opts => options).
|
19
20
|
and_return @config_mock
|
21
|
+
Heirloom::Archive.should_receive(:new).
|
22
|
+
with(:name => 'archive_name',
|
23
|
+
:config => @config_mock).
|
24
|
+
and_return @archive_mock
|
20
25
|
Heirloom::Archive.should_receive(:new).
|
21
26
|
with(:id => '1.0.0',
|
22
27
|
:name => 'archive_name',
|
23
28
|
:config => @config_mock).
|
24
29
|
and_return @archive_mock
|
30
|
+
@archive_mock.should_receive(:domain_exists?).and_return true
|
25
31
|
@cli_destroy = Heirloom::CLI::Destroy.new
|
26
32
|
end
|
27
33
|
|
data/spec/cli/download_spec.rb
CHANGED
@@ -4,14 +4,16 @@ require 'heirloom/cli'
|
|
4
4
|
describe Heirloom do
|
5
5
|
|
6
6
|
before do
|
7
|
-
options = { :name
|
8
|
-
:id
|
9
|
-
:level
|
10
|
-
:output
|
11
|
-
:region
|
7
|
+
options = { :name => 'archive_name',
|
8
|
+
:id => '1.0.0',
|
9
|
+
:level => 'info',
|
10
|
+
:output => '/tmp/test123',
|
11
|
+
:region => 'us-east-1',
|
12
|
+
:base_prefix => 'base' }
|
12
13
|
@logger_mock = mock 'logger'
|
13
14
|
@config_mock = mock 'config'
|
14
15
|
@archive_mock = mock 'archive'
|
16
|
+
@config_mock.stub :logger => @logger_mock
|
15
17
|
Trollop.stub(:options).and_return options
|
16
18
|
Heirloom::HeirloomLogger.should_receive(:new).
|
17
19
|
with(:log_level => 'info').
|
@@ -29,8 +31,9 @@ describe Heirloom do
|
|
29
31
|
end
|
30
32
|
|
31
33
|
it "should download an archive" do
|
32
|
-
@archive_mock.should_receive(:download).with :output
|
33
|
-
:region
|
34
|
+
@archive_mock.should_receive(:download).with :output => '/tmp/test123',
|
35
|
+
:region => 'us-east-1',
|
36
|
+
:base_prefix => 'base'
|
34
37
|
@cli_download.download
|
35
38
|
end
|
36
39
|
|
data/spec/cli/list_spec.rb
CHANGED
@@ -10,6 +10,7 @@ describe Heirloom do
|
|
10
10
|
@logger_stub = stub :debug => true
|
11
11
|
@config_mock = mock 'config'
|
12
12
|
@archive_mock = mock 'archive'
|
13
|
+
@config_mock.stub :logger => @logger_mock
|
13
14
|
Trollop.stub(:options).and_return options
|
14
15
|
Heirloom::HeirloomLogger.should_receive(:new).with(:log_level => 'info').
|
15
16
|
and_return @logger_stub
|
@@ -17,10 +18,15 @@ describe Heirloom do
|
|
17
18
|
with(:logger => @logger_stub,
|
18
19
|
:opts => options).
|
19
20
|
and_return @config_mock
|
21
|
+
Heirloom::Archive.should_receive(:new).
|
22
|
+
with(:name => 'archive_name',
|
23
|
+
:config => @config_mock).
|
24
|
+
and_return @archive_mock
|
20
25
|
Heirloom::Archive.should_receive(:new).
|
21
26
|
with(:name => 'archive_name',
|
22
27
|
:config => @config_mock).
|
23
28
|
and_return @archive_mock
|
29
|
+
@archive_mock.should_receive(:domain_exists?).and_return true
|
24
30
|
@archive_mock.should_receive(:count)
|
25
31
|
@cli_list = Heirloom::CLI::List.new
|
26
32
|
end
|
data/spec/cli/shared_spec.rb
CHANGED
@@ -74,6 +74,33 @@ describe Heirloom do
|
|
74
74
|
@config_mock.should_receive(:secret_key=).with 'the_secret'
|
75
75
|
@object.load_config :logger => @logger_mock, :opts => opts
|
76
76
|
end
|
77
|
+
|
78
|
+
end
|
79
|
+
|
80
|
+
context "testing ensure domain" do
|
81
|
+
before do
|
82
|
+
@archive_mock = mock 'archive'
|
83
|
+
@logger_stub = stub 'logger', :error => true
|
84
|
+
@config_stub = stub 'config', :logger => @logger_stub
|
85
|
+
@object = Object.new
|
86
|
+
@object.extend Heirloom::CLI::Shared
|
87
|
+
Heirloom::Archive.should_receive(:new).
|
88
|
+
with(:name => 'test', :config => @config_stub).
|
89
|
+
and_return @archive_mock
|
90
|
+
end
|
91
|
+
|
92
|
+
it "should ensure the domain for a given archive exists" do
|
93
|
+
@archive_mock.should_receive(:domain_exists?).and_return true
|
94
|
+
@object.ensure_domain_exists :config => @config_stub,
|
95
|
+
:name => 'test'
|
96
|
+
end
|
97
|
+
|
98
|
+
it "should exit if the domain does not exist" do
|
99
|
+
@archive_mock.should_receive(:domain_exists?).and_return false
|
100
|
+
lambda { @object.ensure_domain_exists :config => @config_stub,
|
101
|
+
:name => 'test'}.
|
102
|
+
should raise_error SystemExit
|
103
|
+
end
|
77
104
|
end
|
78
105
|
|
79
106
|
end
|
data/spec/cli/show_spec.rb
CHANGED
@@ -10,6 +10,7 @@ describe Heirloom do
|
|
10
10
|
@logger_stub = stub :debug => true
|
11
11
|
@config_mock = mock 'config'
|
12
12
|
@archive_mock = mock 'archive'
|
13
|
+
@config_mock.stub :logger => @logger_mock
|
13
14
|
Trollop.stub(:options).and_return options
|
14
15
|
Heirloom::HeirloomLogger.should_receive(:new).with(:log_level => 'info').
|
15
16
|
and_return @logger_stub
|
@@ -17,11 +18,16 @@ describe Heirloom do
|
|
17
18
|
with(:logger => @logger_stub,
|
18
19
|
:opts => options).
|
19
20
|
and_return @config_mock
|
21
|
+
Heirloom::Archive.should_receive(:new).
|
22
|
+
with(:name => 'archive_name',
|
23
|
+
:config => @config_mock).
|
24
|
+
and_return @archive_mock
|
20
25
|
Heirloom::Archive.should_receive(:new).
|
21
26
|
with(:name => 'archive_name',
|
22
27
|
:id => '1.0.0',
|
23
28
|
:config => @config_mock).
|
24
29
|
and_return @archive_mock
|
30
|
+
@archive_mock.should_receive(:domain_exists?).and_return true
|
25
31
|
@cli_show = Heirloom::CLI::Show.new
|
26
32
|
end
|
27
33
|
|
data/spec/cli/update_spec.rb
CHANGED
@@ -12,6 +12,7 @@ describe Heirloom do
|
|
12
12
|
@logger_stub = stub :debug => true
|
13
13
|
@config_mock = mock 'config'
|
14
14
|
@archive_mock = mock 'archive'
|
15
|
+
@config_mock.stub :logger => @logger_mock
|
15
16
|
Trollop.stub(:options).and_return options
|
16
17
|
Heirloom::HeirloomLogger.should_receive(:new).with(:log_level => 'info').
|
17
18
|
and_return @logger_stub
|
@@ -19,11 +20,16 @@ describe Heirloom do
|
|
19
20
|
with(:logger => @logger_stub,
|
20
21
|
:opts => options).
|
21
22
|
and_return @config_mock
|
23
|
+
Heirloom::Archive.should_receive(:new).
|
24
|
+
with(:name => 'archive_name',
|
25
|
+
:config => @config_mock).
|
26
|
+
and_return @archive_mock
|
22
27
|
Heirloom::Archive.should_receive(:new).
|
23
28
|
with(:name => 'archive_name',
|
24
29
|
:id => '1.0.0',
|
25
30
|
:config => @config_mock).
|
26
31
|
and_return @archive_mock
|
32
|
+
@archive_mock.should_receive(:domain_exists?).and_return true
|
27
33
|
@cli_update = Heirloom::CLI::Update.new
|
28
34
|
end
|
29
35
|
|
metadata
CHANGED
@@ -1,19 +1,19 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: heirloom
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.4.
|
5
|
-
prerelease:
|
4
|
+
version: 0.4.1rc1
|
5
|
+
prerelease: 5
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
8
8
|
- Brett Weaver
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2012-08-
|
12
|
+
date: 2012-08-17 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rspec
|
16
|
-
requirement: &
|
16
|
+
requirement: &70189313530340 !ruby/object:Gem::Requirement
|
17
17
|
none: false
|
18
18
|
requirements:
|
19
19
|
- - ! '>='
|
@@ -21,10 +21,10 @@ dependencies:
|
|
21
21
|
version: '0'
|
22
22
|
type: :development
|
23
23
|
prerelease: false
|
24
|
-
version_requirements: *
|
24
|
+
version_requirements: *70189313530340
|
25
25
|
- !ruby/object:Gem::Dependency
|
26
26
|
name: fog
|
27
|
-
requirement: &
|
27
|
+
requirement: &70189313529180 !ruby/object:Gem::Requirement
|
28
28
|
none: false
|
29
29
|
requirements:
|
30
30
|
- - ! '>='
|
@@ -32,10 +32,10 @@ dependencies:
|
|
32
32
|
version: '0'
|
33
33
|
type: :runtime
|
34
34
|
prerelease: false
|
35
|
-
version_requirements: *
|
35
|
+
version_requirements: *70189313529180
|
36
36
|
- !ruby/object:Gem::Dependency
|
37
37
|
name: grit
|
38
|
-
requirement: &
|
38
|
+
requirement: &70189313528440 !ruby/object:Gem::Requirement
|
39
39
|
none: false
|
40
40
|
requirements:
|
41
41
|
- - ! '>='
|
@@ -43,10 +43,10 @@ dependencies:
|
|
43
43
|
version: '0'
|
44
44
|
type: :runtime
|
45
45
|
prerelease: false
|
46
|
-
version_requirements: *
|
46
|
+
version_requirements: *70189313528440
|
47
47
|
- !ruby/object:Gem::Dependency
|
48
48
|
name: logger
|
49
|
-
requirement: &
|
49
|
+
requirement: &70189313527540 !ruby/object:Gem::Requirement
|
50
50
|
none: false
|
51
51
|
requirements:
|
52
52
|
- - ! '>='
|
@@ -54,10 +54,10 @@ dependencies:
|
|
54
54
|
version: '0'
|
55
55
|
type: :runtime
|
56
56
|
prerelease: false
|
57
|
-
version_requirements: *
|
57
|
+
version_requirements: *70189313527540
|
58
58
|
- !ruby/object:Gem::Dependency
|
59
59
|
name: trollop
|
60
|
-
requirement: &
|
60
|
+
requirement: &70189313526840 !ruby/object:Gem::Requirement
|
61
61
|
none: false
|
62
62
|
requirements:
|
63
63
|
- - ! '>='
|
@@ -65,7 +65,7 @@ dependencies:
|
|
65
65
|
version: '0'
|
66
66
|
type: :runtime
|
67
67
|
prerelease: false
|
68
|
-
version_requirements: *
|
68
|
+
version_requirements: *70189313526840
|
69
69
|
description: I help build and manage building tar.gz files and deploying them into
|
70
70
|
the cloud
|
71
71
|
email:
|
@@ -164,16 +164,13 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
164
164
|
version: '0'
|
165
165
|
segments:
|
166
166
|
- 0
|
167
|
-
hash:
|
167
|
+
hash: 3075151930949687714
|
168
168
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
169
169
|
none: false
|
170
170
|
requirements:
|
171
|
-
- - ! '
|
171
|
+
- - ! '>'
|
172
172
|
- !ruby/object:Gem::Version
|
173
|
-
version:
|
174
|
-
segments:
|
175
|
-
- 0
|
176
|
-
hash: 1382939958455203904
|
173
|
+
version: 1.3.1
|
177
174
|
requirements: []
|
178
175
|
rubyforge_project: heirloom
|
179
176
|
rubygems_version: 1.8.16
|