[lvmd] run test on virtual machine
@@ -7,9 +7,30 @@ jobs:
steps:
- checkout
- run: make test
+ test_lvmd:
+ machine: true
+ working_directory: /home/circleci/work
+ steps:
+ - checkout
+ - run:
+ name: install lvm
+ command: |
+ sudo apt-get update
+ sudo apt-get -y install --no-install-recommends lvm2
+ - run:
+ name: setup golang
+ command: |
+ sudo rm -rf /usr/local/go
+ GO_VERSION=1.12.5
+ curl -fsSL -o go${GO_VERSION}.linux-amd64.tar.gz https://dl.google.com/go/go${GO_VERSION}.linux-amd64.tar.gz
+ sudo tar -C /usr/local -xzf go${GO_VERSION}.linux-amd64.tar.gz
+ - run:
+ name: run test
+ command: sudo env "GO111MODULE=on" "CIRCLECI=${CIRCLECI}" "CIRCLECI_EXECUTOR=machine" /usr/local/go/bin/go test -mod=vendor -race -v ./lvmd
workflows:
version: 2
main:
jobs:
- build
+ - test_lvmd
