Skip to content

Commit

Permalink
Merge pull request #26 from YuviGold/test-with-docker
Browse files Browse the repository at this point in the history
Test with docker - make test
  • Loading branch information
milosgajdos authored Jul 30, 2020
2 parents 24ae257 + c2ef9db commit 997445a
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 0 deletions.
6 changes: 6 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
test:
docker-compose run --rm test make _test

_test:
go test

13 changes: 13 additions & 0 deletions docker-compose.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
version: '3'

services:
test:
image: golang
cap_add:
- CAP_NET_ADMIN
volumes:
- ${PWD}:/src
- ${HOME}/.cache/go-build:/go/pkg/mod
working_dir: /src
environment:
- GOCACHE=/go/pkg/mod

0 comments on commit 997445a

Please sign in to comment.