r10k 3.9.2 → 3.9.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 1a9adbfc4e0f834dfdec6b9703325c61c617ec21d2261034aa3ba702ae9a0710
4
- data.tar.gz: f46775713081247843c4189a13349458c7dd2691ce0e9cf99ae02b1e3d21bceb
3
+ metadata.gz: 46561d19b47798865a0cb7a986deb0dc5f4fadc9094414ca25958a41395f07fa
4
+ data.tar.gz: 3d604c77ed0d1735127c18737a1bbb0aacc65ad17a789e4b154e05283e240ac3
5
5
  SHA512:
6
- metadata.gz: 979de4fa8399e28f4fdf742b8ca5a23a4f116a96a7131ad93bcdb859db16aae59cea5e45fd8fa03c98229fd1f321f25334775f4a4efe27eb90464bac2b1d8b37
7
- data.tar.gz: efefb07a7a85813a0b967110e05a28a8e4badf5987cd13fec95b37dafd8dc3fdf86081f1c6a023a667c0a8f5416e53cd50ef84bb5fd39a6f70085ff2737e5913
6
+ metadata.gz: bfff74f4746cf25caf1586e6cfd4dea01e810203d59dab4de2072d35ba42bd90e5f1e2a904e117c1fba63de20666ab4b98f26ad6552ecfd1b4ce6c814eb65c0b
7
+ data.tar.gz: 5a3972217637238fd8f9bfd1c810e26a901764b496d7dc195c26a0c567111ab03c621e4cef20564f4c8ef57c6292255a8871625ffe3e15597ba6765d39428002
data/CHANGELOG.mkd CHANGED
@@ -4,7 +4,13 @@ CHANGELOG
4
4
  Unreleased
5
5
  ----------
6
6
 
7
+ 3.9.3
8
+ -----
9
+
10
+ - Fixes a regression when using `--default_branch_override` with Puppetfiles containing Forge modules. [#1173](https://github.com/puppetlabs/r10k/issues/1173)
11
+
7
12
  3.9.2
13
+ -----
8
14
 
9
15
  - Makes the third parameter to R10K::Actions optional, restoring backwards compatability broken in 3.9.1.
10
16
 
@@ -50,7 +50,7 @@ class R10K::Module::Forge < R10K::Module::Base
50
50
  :version => :expected_version,
51
51
  :source => ::R10K::Util::Setopts::Ignore,
52
52
  :type => ::R10K::Util::Setopts::Ignore,
53
- })
53
+ }, :raise_on_unhandled => false)
54
54
 
55
55
  @expected_version ||= current_version || :latest
56
56
 
@@ -52,7 +52,7 @@ class R10K::Module::Git < R10K::Module::Base
52
52
  :git => :remote,
53
53
  :default_branch => :default_ref,
54
54
  :default_branch_override => :default_override_ref,
55
- })
55
+ }, :raise_on_unhandled => false)
56
56
 
57
57
  force = @overrides.dig(:modules, :force)
58
58
  @force = force == false ? false : true
@@ -50,7 +50,7 @@ class R10K::Module::SVN < R10K::Module::Base
50
50
  :revision => :expected_revision,
51
51
  :username => :self,
52
52
  :password => :self
53
- })
53
+ }, :raise_on_unhandled => false)
54
54
 
55
55
  @working_dir = R10K::SVN::WorkingDir.new(@path, :username => @username, :password => @password)
56
56
  end
data/lib/r10k/version.rb CHANGED
@@ -2,5 +2,5 @@ module R10K
2
2
  # When updating to a new major (X) or minor (Y) version, include `#major` or
3
3
  # `#minor` (respectively) in your commit message to trigger the appropriate
4
4
  # release. Otherwise, a new patch (Z) version will be released.
5
- VERSION = '3.9.2'
5
+ VERSION = '3.9.3'
6
6
  end
@@ -119,14 +119,6 @@ describe R10K::Module::Git do
119
119
  allow(mock_repo).to receive(:head).and_return('abc123')
120
120
  end
121
121
 
122
- context "when option is unrecognized" do
123
- let(:opts) { { unrecognized: true } }
124
-
125
- it "raises an error" do
126
- expect { test_module(opts) }.to raise_error(ArgumentError, /cannot handle option 'unrecognized'/)
127
- end
128
- end
129
-
130
122
  describe "desired ref" do
131
123
  context "when no desired ref is given" do
132
124
  it "defaults to master" do
@@ -76,4 +76,21 @@ describe R10K::Module do
76
76
  R10K::Module.new('bar!quux', '/modulepath', {version: ["NOPE NOPE NOPE NOPE!"]})
77
77
  }.to raise_error RuntimeError, /doesn't have an implementation/
78
78
  end
79
+
80
+ describe 'when a user passes a `default_branch_override`' do
81
+ [ ['name', {git: 'git url'}],
82
+ ['name', {type: 'git', source: 'git url'}],
83
+ ['name', {svn: 'svn url'}],
84
+ ['name', {type: 'svn', source: 'svn url'}],
85
+ ['namespace-name', {version: '8.0.0'}],
86
+ ['namespace-name', {type: 'forge', version: '8.0.0'}]
87
+ ].each do |(name, options)|
88
+ it 'can handle the default_branch_override option' do
89
+ expect {
90
+ obj = R10K::Module.new(name, '/modulepath', options.merge({default_branch_override: 'foo'}))
91
+ expect(obj).to be_a_kind_of(R10K::Module::Base)
92
+ }.not_to raise_error
93
+ end
94
+ end
95
+ end
79
96
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: r10k
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.9.2
4
+ version: 3.9.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Adrien Thebo
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-06-19 00:00:00.000000000 Z
11
+ date: 2021-06-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: colored2
@@ -576,7 +576,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
576
576
  - !ruby/object:Gem::Version
577
577
  version: '0'
578
578
  requirements: []
579
- rubygems_version: 3.0.3
579
+ rubygems_version: 3.0.8
580
580
  signing_key:
581
581
  specification_version: 4
582
582
  summary: Puppet environment and module deployment