Skip to content

Commit

Permalink
Makefile: fix ut testing for converter package
Browse files Browse the repository at this point in the history
The converter package needs use sudo to access privileged xattr
of file (containerd apply oci whiteout file to overlayfs whiteout).

Signed-off-by: Yan Song <[email protected]>
  • Loading branch information
imeoer committed Apr 2, 2022
1 parent f3f9239 commit 9fb4dfe
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
strategy:
matrix:
go-version:
- 1.16
- 1.17
platform:
- ubuntu-latest
runs-on: ${{ matrix.platform }}
Expand Down Expand Up @@ -45,7 +45,7 @@ jobs:
strategy:
matrix:
go-version:
- 1.16
- 1.17
platform:
- ubuntu-latest
runs-on: ${{ matrix.platform }}
Expand Down
4 changes: 3 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ all: clear build
VERSION=$(shell git rev-parse --verify HEAD --short=7)
BRANCH=$(shell git rev-parse --abbrev-ref HEAD)
PACKAGES ?= $(shell go list ./... | grep -v /vendor/)
SUDO = $(shell which sudo)
GO_EXECUTABLE_PATH ?= $(shell which go)
#GOPROXY ?= https://goproxy.io

ifdef GOPROXY
Expand Down Expand Up @@ -39,7 +41,7 @@ check: vet

.PHONY: test
test:
go test -race -v -mod=mod -cover ${PACKAGES}
$(SUDO) NYDUS_BUILDER=${NYDUS_BUILDER} NYDUS_NYDUSD=${NYDUS_NYDUSD} ${GO_EXECUTABLE_PATH} test -race -v -mod=mod -cover ${PACKAGES}

.PHONY: cover
cover:
Expand Down

0 comments on commit 9fb4dfe

Please sign in to comment.