knife-changelog 1.0.5 → 1.0.6

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
  SHA256:
3
- metadata.gz: aa4e42103311806ff7c88b829d826fb4e8546e1d17c463d8bb4082b31a88f479
4
- data.tar.gz: 189c09706beb96b561e124719e396bdac38fba5f1205cdff0e8a5450a8cb2d2c
3
+ metadata.gz: 3a5811fea619f544617e97994433350e5c0206b46902d435a4320f5ef057e4e8
4
+ data.tar.gz: 77d0091e020ba853008dec8b603f3ba3c7e4c4181532edfbf8456e0d76954a33
5
5
  SHA512:
6
- metadata.gz: 5d22e0aedafda4f36d0650718965c2ad1c39e17edf9c72a683f0b94ed498696ec4880a9387330a4de82a135ab7f5b8ac1232e0c8435d073e5f6c9138b6497465
7
- data.tar.gz: 6b7d85d9a2ed9e500fb533106ea3e258ae8fcddb81406a7adf9aaccd1ad8ec2f64396b076ed58e44fc9f9e0956703c14ef521ef0c68cb3f1b194deef31450fe7
6
+ metadata.gz: eabfd3352b56cf74f7e4c3a55b9acf7ac3b20786f837b9bb9cd228e6f343411bb1d976759969f26869044a030e2f86173152d6f8b7848d292ab4a1d4c2a1eb60
7
+ data.tar.gz: 8f7c33a094d3c964dfaf2e7102ba05569077e2a49658e8932bd4657d0e90c35a8e45e5b1c663529d935238b1761a0df40b5fba9f586504eb3cfa3bba2fd1275d
@@ -17,7 +17,7 @@ class KnifeChangelog
17
17
  end
18
18
 
19
19
  def all_cookbooks
20
- policy.all_possible_dep_names
20
+ policy.solution_dependencies.cookbook_deps_for_lock.map { |k, v| k.scan(/(.*) \(.*\)/).last.first }
21
21
  end
22
22
 
23
23
  # return true if cookbook is not already listed as dependency
@@ -1,5 +1,5 @@
1
1
  module Knife
2
2
  module Changelog
3
- VERSION = '1.0.5'
3
+ VERSION = '1.0.6'
4
4
  end
5
5
  end
@@ -147,6 +147,32 @@ describe KnifeChangelog::Changelog do
147
147
  expect { changelog.run(%w[outdated1]) }.to raise_error(NotImplementedError)
148
148
  end
149
149
  end
150
+
151
+ context 'whith --allow-update-all ' do
152
+ let(:options) do
153
+ { "allow_update_all": true }
154
+ end
155
+
156
+ it 'should compute the changelog of all dependencies' do
157
+ mock_git('second_out_of_date', <<-EOH)
158
+ aaaaaa commit in second_out_of_date
159
+ bbbbbb bugfix in second_out_of_date
160
+ EOH
161
+ mock_git('outdated1', <<-EOH)
162
+ aaaaaa commit in outdated1
163
+ bbbbbb bugfix in outdated1
164
+ EOH
165
+ mock_git('uptodate', '')
166
+
167
+ expect(changelog).to receive(:supermarkets_for).with('outdated1')
168
+ .and_return(["https://mysupermarket2.io"])
169
+ expect(changelog).to receive(:supermarkets_for).with('second_out_of_date')
170
+ .and_return(["https://mysupermarket2.io"])
171
+ expect(changelog).to receive(:supermarkets_for).with('uptodate')
172
+ .and_return(["https://mysupermarket2.io"])
173
+ changelog.run([])
174
+ end
175
+ end
150
176
  end
151
177
  end
152
178
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: knife-changelog
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.5
4
+ version: 1.0.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gregoire Seux
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-11-24 00:00:00.000000000 Z
11
+ date: 2017-12-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -213,7 +213,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
213
213
  version: '0'
214
214
  requirements: []
215
215
  rubyforge_project:
216
- rubygems_version: 2.7.2
216
+ rubygems_version: 2.7.3
217
217
  signing_key:
218
218
  specification_version: 4
219
219
  summary: Facilitate access to cookbooks changelog