From 4c04e3c06bc7d7b832ce3a35192826ec2b111f16 Mon Sep 17 00:00:00 2001 From: kun Date: Tue, 6 Aug 2019 10:09:47 +0800 Subject: [PATCH] add tests for router mode --- .circleci/config.yml | 30 +++++++++++++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index c94e8b3..3c6d67a 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -3,7 +3,7 @@ # Check https://circleci.com/docs/2.0/language-go/ for more details version: 2 jobs: - build: + proxy-mode: docker: - image: circleci/golang:1.12 working_directory: /go/src/github.com/goproxyio/goproxy/ @@ -25,3 +25,31 @@ jobs: - run: name: run real test command: bash test/get_test.sh + router-mode: + docker: + - image: circleci/golang:1.12 + working_directory: /go/src/github.com/goproxyio/goproxy/ + steps: + - checkout + - run: + name: install deps + command: make tidy + - run: + name: test self + command: make test + - run: + name: build bin + command: make build + - run: + name: run proxy backgroud to test real + command: export GO111MODULE=on && bin/goproxy -proxy https://goproxy.io -exclude "golang.org" + background: true + - run: + name: run real test + command: bash test/get_test.sh +workflows: + version: 2 + build_and_test: + jobs: + - proxy-mode + - router-mode