Skip to content

Commit

Permalink
Go 1.12
Browse files Browse the repository at this point in the history
  • Loading branch information
hmarr committed Jun 3, 2019
1 parent 3689ca0 commit 6de3b7f
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ RUN echo "deb http://ppa.launchpad.net/ondrej/php/ubuntu bionic main" >> /etc/ap
### GO

# Install Go and dep
RUN curl https://dl.google.com/go/go1.11.5.linux-amd64.tar.gz | tar -xz -C /opt \
RUN curl https://dl.google.com/go/go1.12.5.linux-amd64.tar.gz | tar -xz -C /opt \
&& wget -O /opt/go/bin/dep https://github.com/golang/dep/releases/download/0.5.2/dep-linux-amd64 \
&& chmod +x /opt/go/bin/dep \
&& mkdir /opt/go/gopath
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,8 @@ def updated_go_sum_content

RESOLVABILITY_ERROR_REGEXES = [
/go: .*: git fetch .*: exit status 128/.freeze,
/go: verifying .*: checksum mismatch/.freeze,
/build .*: cannot find module for path/.freeze
/verifying .*: checksum mismatch/.freeze,
/build .*: cannot find module providing package/.freeze
].freeze
MODULE_PATH_MISMATCH_REGEXES = [
/go: ([^@\s]+)(?:@[^\s]+)?: .* has non-.* module path "(.*)" at/,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,17 @@

it { is_expected.to include(%(rsc.io/quote v1.5.2\n)) }

context "for a go 1.11 go.mod" do
let(:go_mod_body) do
fixture("go_mods", go_mod_fixture_name).sub(/go 1.12/, "")
end
it { is_expected.to_not include("go 1.") }
end

context "for a go 1.12 go.mod" do
it { is_expected.to include("go 1.12") }
end

context "with a go.sum" do
let(:go_sum) do
Dependabot::DependencyFile.new(name: "go.sum", content: go_sum_body)
Expand Down
2 changes: 2 additions & 0 deletions go_modules/spec/fixtures/go_mods/go.mod
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
module github.com/dependabot/vgotest

go 1.12

require (
// The actual repo is fatih/color, but including the capital
// helps us test that we preserve caps
Expand Down

0 comments on commit 6de3b7f

Please sign in to comment.