dpl 1.4.6.travis.124.2 → 1.4.6.travis.125.2

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: 9dc98e6648870b71534e836f7ff62f719d987a22
4
- data.tar.gz: 5e241cfe05f36cd03dd3178ea2fdc9a74816b078
3
+ metadata.gz: 79e537d92d2b9b9b26db93238a69e4487f11cd7e
4
+ data.tar.gz: 85c4e482cee9f875a76013cb99d10f451ea01fad
5
5
  SHA512:
6
- metadata.gz: c77d4eb287d01b0ac7a332a51a7ab7215109c8bc19d861392662a45a12733ef53d1092b47cbd3fc3a9230bc6ca5d63b23737531889bb9b06592dba2ec0c433e0
7
- data.tar.gz: 09730c624d554108e2b64b209f0058edea1fc610dbb9abf7b211728d9ee462ae60e7328d9b7320712d86215c2d5e0e1ddb16146c7f37a16d4001cfb9146af408
6
+ metadata.gz: b64e5e0327b67bd23257318619cd7407a3dfd46c646d1d2678358772d996290dcc5cf1a457da33e039989fc60d0ef482519ef6aedf73c276d257d36db9e7528b
7
+ data.tar.gz: be46e7af3e2d0ccde0874fce680b161277f94ee084ece3bbab6035444fee02b5de34f98ceac551160e16e388494203132dfaf8c830d1be110639c202d18d7b21
data/Gemfile CHANGED
@@ -16,5 +16,5 @@ group :openshift do
16
16
  end
17
17
 
18
18
  group :rubygems do
19
- gem 'gems'
19
+ gem 'gems', '~>0.8.3'
20
20
  end
@@ -38,7 +38,11 @@ module DPL
38
38
  setup_gem
39
39
  context.shell "gem build #{gemspec || option(:gem)}.gemspec"
40
40
  Dir.glob("#{gemspec || option(:gem)}-*.gem") do |f|
41
- log ::Gems.push File.new f
41
+ if options[:host]
42
+ log ::Gems.push(File.new(f), options[:host])
43
+ else
44
+ log ::Gems.push(File.new f)
45
+ end
42
46
  end
43
47
  end
44
48
  end
@@ -43,7 +43,6 @@ describe DPL::Provider::RubyGems do
43
43
  describe :push_app do
44
44
  after(:each) do
45
45
  File.should_receive(:new).with('File').and_return('Test file')
46
- ::Gems.should_receive(:push).with('Test file').and_return('Yes!')
47
46
  provider.should_receive(:log).with('Yes!')
48
47
  provider.push_app
49
48
  end
@@ -52,18 +51,28 @@ describe DPL::Provider::RubyGems do
52
51
  provider.options.update(:app => 'example')
53
52
  provider.context.should_receive(:shell).with("gem build example.gemspec")
54
53
  Dir.should_receive(:glob).with('example-*.gem').and_yield('File')
54
+ ::Gems.should_receive(:push).with('Test file').and_return('Yes!')
55
55
  end
56
56
 
57
57
  example "with options[:gem]" do
58
58
  provider.options.update(:gem => 'example-gem')
59
59
  provider.context.should_receive(:shell).with("gem build example-gem.gemspec")
60
60
  Dir.should_receive(:glob).with('example-gem-*.gem').and_yield('File')
61
+ ::Gems.should_receive(:push).with('Test file').and_return('Yes!')
61
62
  end
62
63
 
63
64
  example "with options[:gemspec]" do
64
65
  provider.options.update(:gemspec => 'blah.gemspec')
65
66
  provider.context.should_receive(:shell).with("gem build blah.gemspec")
66
67
  Dir.should_receive(:glob).with('blah-*.gem').and_yield('File')
68
+ ::Gems.should_receive(:push).with('Test file').and_return('Yes!')
69
+ end
70
+
71
+ example "with options[:host]" do
72
+ provider.options.update(:host => 'http://example.com')
73
+ provider.context.should_receive(:shell).with("gem build example.gemspec")
74
+ Dir.should_receive(:glob).with('example-*.gem').and_yield('File')
75
+ ::Gems.should_receive(:push).with('Test file', host='http://example.com').and_return('Yes!')
67
76
  end
68
77
  end
69
78
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dpl
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.4.6.travis.124.2
4
+ version: 1.4.6.travis.125.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Konstantin Haase