dependabot-bundler 0.154.1 → 0.154.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
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 9b31ba93254309940073353b581acd7631e6db21a6ffad47d3d88afe4b08a53d
|
|
4
|
+
data.tar.gz: bc63d0f4b4455ad8c2c08da23a3d47d5e8dd567061b415c386b0453b313776fb
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: dd79eec594396d1cb334ae5ef2020669b0e3edc96ac5284c2c5ee1ce65cb804ca9f266f3539e14daf7636fb752642f84d9d085f2f8e465a445a1e607b346f6e0
|
|
7
|
+
data.tar.gz: 49156e6d573d6290582776eaf7e76b1339d0341222e521d52c3f858e9de997474e0559a27382ef9f0ae49ae8140ee8c08d9fc3401a0bbb722a8360bb716c179c
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
require "native_spec_helper"
|
|
4
|
+
require "shared_contexts"
|
|
5
|
+
|
|
6
|
+
RSpec.describe Functions::ForceUpdater do
|
|
7
|
+
include_context "in a temporary bundler directory"
|
|
8
|
+
include_context "stub rubygems compact index"
|
|
9
|
+
|
|
10
|
+
let(:force_updater) do
|
|
11
|
+
described_class.new(
|
|
12
|
+
dependency_name: dependency_name,
|
|
13
|
+
target_version: target_version,
|
|
14
|
+
gemfile_name: gemfile_name,
|
|
15
|
+
lockfile_name: lockfile_name,
|
|
16
|
+
update_multiple_dependencies: update_multiple_dependencies
|
|
17
|
+
)
|
|
18
|
+
end
|
|
19
|
+
let(:gemfile_name) { "Gemfile" }
|
|
20
|
+
let(:lockfile_name) { "Gemfile.lock" }
|
|
21
|
+
let(:update_multiple_dependencies) { true }
|
|
22
|
+
|
|
23
|
+
describe "#run" do
|
|
24
|
+
subject(:force_update) do
|
|
25
|
+
in_tmp_folder { force_updater.run }
|
|
26
|
+
end
|
|
27
|
+
|
|
28
|
+
context "with a version conflict" do
|
|
29
|
+
let(:target_version) { "3.6.0" }
|
|
30
|
+
let(:dependency_name) { "rspec-support" }
|
|
31
|
+
let(:project_name) { "version_conflict" }
|
|
32
|
+
|
|
33
|
+
it "updates the conflicting dependencies" do
|
|
34
|
+
updated_deps, _specs = force_update
|
|
35
|
+
expect(updated_deps).to eq([{ name: "rspec-support" }, { name: "rspec-mocks" }])
|
|
36
|
+
end
|
|
37
|
+
|
|
38
|
+
context "when updating a single dependency" do
|
|
39
|
+
let(:update_multiple_dependencies) { false }
|
|
40
|
+
|
|
41
|
+
it { expect { force_update }.to raise_error(Bundler::VersionConflict) }
|
|
42
|
+
end
|
|
43
|
+
end
|
|
44
|
+
|
|
45
|
+
context "with a version conflict in gems rb" do
|
|
46
|
+
let(:target_version) { "3.6.0" }
|
|
47
|
+
let(:dependency_name) { "rspec-support" }
|
|
48
|
+
let(:project_name) { "version_conflict_gems_rb" }
|
|
49
|
+
let(:gemfile_name) { "gems.rb" }
|
|
50
|
+
let(:lockfile_name) { "gems.locked" }
|
|
51
|
+
|
|
52
|
+
it "updates the conflicting dependencies" do
|
|
53
|
+
updated_deps, _specs = force_update
|
|
54
|
+
expect(updated_deps).to eq([{ name: "rspec-support" }, { name: "rspec-mocks" }])
|
|
55
|
+
end
|
|
56
|
+
end
|
|
57
|
+
end
|
|
58
|
+
end
|
|
@@ -92,5 +92,13 @@ RSpec.describe Functions::VersionResolver do
|
|
|
92
92
|
its([:version]) { is_expected.to eq(Gem::Version.new("1.4.0")) }
|
|
93
93
|
its([:fetcher]) { is_expected.to eq("Bundler::Fetcher::Dependency") }
|
|
94
94
|
end
|
|
95
|
+
|
|
96
|
+
context "with no update possible due to a version conflict" do
|
|
97
|
+
let(:project_name) { "version_conflict_with_listed_subdep" }
|
|
98
|
+
let(:dependency_name) { "rspec-mocks" }
|
|
99
|
+
let(:requirement_string) { ">= 0" }
|
|
100
|
+
|
|
101
|
+
its([:version]) { is_expected.to eq(Gem::Version.new("3.6.0")) }
|
|
102
|
+
end
|
|
95
103
|
end
|
|
96
104
|
end
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
require "native_spec_helper"
|
|
4
|
+
require "shared_contexts"
|
|
5
|
+
|
|
6
|
+
RSpec.describe Functions::ForceUpdater do
|
|
7
|
+
include_context "in a temporary bundler directory"
|
|
8
|
+
include_context "stub rubygems compact index"
|
|
9
|
+
|
|
10
|
+
let(:force_updater) do
|
|
11
|
+
described_class.new(
|
|
12
|
+
dependency_name: dependency_name,
|
|
13
|
+
target_version: target_version,
|
|
14
|
+
gemfile_name: gemfile_name,
|
|
15
|
+
lockfile_name: lockfile_name,
|
|
16
|
+
update_multiple_dependencies: update_multiple_dependencies
|
|
17
|
+
)
|
|
18
|
+
end
|
|
19
|
+
let(:gemfile_name) { "Gemfile" }
|
|
20
|
+
let(:lockfile_name) { "Gemfile.lock" }
|
|
21
|
+
let(:update_multiple_dependencies) { true }
|
|
22
|
+
|
|
23
|
+
describe "#run" do
|
|
24
|
+
subject(:force_update) do
|
|
25
|
+
in_tmp_folder { force_updater.run }
|
|
26
|
+
end
|
|
27
|
+
|
|
28
|
+
context "with a version conflict" do
|
|
29
|
+
let(:target_version) { "3.6.0" }
|
|
30
|
+
let(:dependency_name) { "rspec-support" }
|
|
31
|
+
let(:project_name) { "version_conflict" }
|
|
32
|
+
|
|
33
|
+
it "updates the conflicting dependencies" do
|
|
34
|
+
updated_deps, _specs = force_update
|
|
35
|
+
expect(updated_deps).to eq([{ name: "rspec-support" }, { name: "rspec-mocks" }])
|
|
36
|
+
end
|
|
37
|
+
|
|
38
|
+
context "when updating a single dependency" do
|
|
39
|
+
let(:update_multiple_dependencies) { false }
|
|
40
|
+
|
|
41
|
+
it { expect { force_update }.to raise_error(Bundler::VersionConflict) }
|
|
42
|
+
end
|
|
43
|
+
end
|
|
44
|
+
|
|
45
|
+
context "with a version conflict in gems rb" do
|
|
46
|
+
let(:target_version) { "3.6.0" }
|
|
47
|
+
let(:dependency_name) { "rspec-support" }
|
|
48
|
+
let(:project_name) { "version_conflict_gems_rb" }
|
|
49
|
+
let(:gemfile_name) { "gems.rb" }
|
|
50
|
+
let(:lockfile_name) { "gems.locked" }
|
|
51
|
+
|
|
52
|
+
it "updates the conflicting dependencies" do
|
|
53
|
+
updated_deps, _specs = force_update
|
|
54
|
+
expect(updated_deps).to eq([{ name: "rspec-support" }, { name: "rspec-mocks" }])
|
|
55
|
+
end
|
|
56
|
+
end
|
|
57
|
+
end
|
|
58
|
+
end
|
|
@@ -92,5 +92,13 @@ RSpec.describe Functions::VersionResolver do
|
|
|
92
92
|
its([:version]) { is_expected.to eq(Gem::Version.new("1.4.0")) }
|
|
93
93
|
its([:fetcher]) { is_expected.to eq("Bundler::Fetcher::Dependency") }
|
|
94
94
|
end
|
|
95
|
+
|
|
96
|
+
context "with no update possible due to a version conflict" do
|
|
97
|
+
let(:project_name) { "version_conflict_with_listed_subdep" }
|
|
98
|
+
let(:dependency_name) { "rspec-mocks" }
|
|
99
|
+
let(:requirement_string) { ">= 0" }
|
|
100
|
+
|
|
101
|
+
its([:version]) { is_expected.to eq(Gem::Version.new("3.6.0")) }
|
|
102
|
+
end
|
|
95
103
|
end
|
|
96
104
|
end
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: dependabot-bundler
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.154.
|
|
4
|
+
version: 0.154.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Dependabot
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2021-06-
|
|
11
|
+
date: 2021-06-17 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: dependabot-common
|
|
@@ -16,14 +16,14 @@ dependencies:
|
|
|
16
16
|
requirements:
|
|
17
17
|
- - '='
|
|
18
18
|
- !ruby/object:Gem::Version
|
|
19
|
-
version: 0.154.
|
|
19
|
+
version: 0.154.2
|
|
20
20
|
type: :runtime
|
|
21
21
|
prerelease: false
|
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
|
23
23
|
requirements:
|
|
24
24
|
- - '='
|
|
25
25
|
- !ruby/object:Gem::Version
|
|
26
|
-
version: 0.154.
|
|
26
|
+
version: 0.154.2
|
|
27
27
|
- !ruby/object:Gem::Dependency
|
|
28
28
|
name: byebug
|
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -202,6 +202,7 @@ files:
|
|
|
202
202
|
- helpers/v1/spec/functions/conflicting_dependency_resolver_spec.rb
|
|
203
203
|
- helpers/v1/spec/functions/dependency_source_spec.rb
|
|
204
204
|
- helpers/v1/spec/functions/file_parser_spec.rb
|
|
205
|
+
- helpers/v1/spec/functions/force_updater_spec.rb
|
|
205
206
|
- helpers/v1/spec/functions/version_resolver_spec.rb
|
|
206
207
|
- helpers/v1/spec/native_spec_helper.rb
|
|
207
208
|
- helpers/v1/spec/shared_contexts.rb
|
|
@@ -222,6 +223,7 @@ files:
|
|
|
222
223
|
- helpers/v2/spec/functions/conflicting_dependency_resolver_spec.rb
|
|
223
224
|
- helpers/v2/spec/functions/dependency_source_spec.rb
|
|
224
225
|
- helpers/v2/spec/functions/file_parser_spec.rb
|
|
226
|
+
- helpers/v2/spec/functions/force_updater_spec.rb
|
|
225
227
|
- helpers/v2/spec/functions/version_resolver_spec.rb
|
|
226
228
|
- helpers/v2/spec/functions_spec.rb
|
|
227
229
|
- helpers/v2/spec/native_spec_helper.rb
|