From edd5233a0c726848385efdf530cf430d5d9ea83d Mon Sep 17 00:00:00 2001 From: josebarn Date: Sun, 13 Aug 2017 08:12:14 -0300 Subject: [PATCH 1/5] modified readme for pr --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index 38ed11d..0df7a67 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,5 @@ # drone-with-go [![Build Status](http://beta.drone.io/api/badges/drone-demos/drone-with-go/status.svg)](http://beta.drone.io/drone-demos/drone-with-go) [![Build Status](https://aircover.co/badges/drone-demos/drone-with-go/coverage.svg)](https://aircover.co/drone-demos/drone-with-go) An example of how to test Go code with Drone. + +Inspect the .drone.yml file for details on the build steps for this simple go project. From fe74afa94c56f655f2d8f9d1864ad5f3043eafcf Mon Sep 17 00:00:00 2001 From: josebarn Date: Sun, 13 Aug 2017 08:15:58 -0300 Subject: [PATCH 2/5] Added pipeline section to .drone.yml file --- .drone.yml | 26 +++++++++++++++----------- 1 file changed, 15 insertions(+), 11 deletions(-) diff --git a/.drone.yml b/.drone.yml index b90ee66..acf7cd1 100644 --- a/.drone.yml +++ b/.drone.yml @@ -1,12 +1,16 @@ -build: - image: golang:1.5 - environment: - - GO15VENDOREXPERIMENT=1 - - CGO_ENABLED=0 - commands: - - go test -cover -coverprofile coverage.out +workspace: + base: /go + path: src/github.com/josebarn/drone-with-go +pipeline: + build: + image: golang:1.5 + environment: + - GO15VENDOREXPERIMENT=1 + - CGO_ENABLED=0 + commands: + - go test -cover -coverprofile coverage.out -publish: - coverage: - when: - branch: master + publish: + coverage: + when: + branch: master From f14c20e8328f65eba5ab6a679dabb5f5300d0a6e Mon Sep 17 00:00:00 2001 From: josebarn Date: Sun, 13 Aug 2017 08:17:45 -0300 Subject: [PATCH 3/5] Removed pipeline section to .drone.yml file --- .drone.yml | 3 --- 1 file changed, 3 deletions(-) diff --git a/.drone.yml b/.drone.yml index acf7cd1..85a3386 100644 --- a/.drone.yml +++ b/.drone.yml @@ -1,6 +1,3 @@ -workspace: - base: /go - path: src/github.com/josebarn/drone-with-go pipeline: build: image: golang:1.5 From 12363097f5ed4433914ce35fb684a90eb628c992 Mon Sep 17 00:00:00 2001 From: josebarn Date: Sun, 13 Aug 2017 08:36:55 -0300 Subject: [PATCH 4/5] trying again --- main_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/main_test.go b/main_test.go index 887a4df..4b3811b 100644 --- a/main_test.go +++ b/main_test.go @@ -1,5 +1,5 @@ package main - + import ( "os" "testing" From cf1fa4475f5a995d9f0b330d28a382eba03d216e Mon Sep 17 00:00:00 2001 From: josebarn Date: Sun, 13 Aug 2017 09:43:55 -0300 Subject: [PATCH 5/5] trying again --- .drone.yml | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/.drone.yml b/.drone.yml index 85a3386..5415c42 100644 --- a/.drone.yml +++ b/.drone.yml @@ -1,13 +1,12 @@ pipeline: build: - image: golang:1.5 - environment: - - GO15VENDOREXPERIMENT=1 - - CGO_ENABLED=0 + image: ${IMAGE} commands: - - go test -cover -coverprofile coverage.out + - go build + - go test - publish: - coverage: - when: - branch: master +matrix: + IMAGE: + - golang:1.7 + - golang:1.8 + - golang:latest