Skip to content

Commit

Permalink
add test to CI for example directory
Browse files Browse the repository at this point in the history
  • Loading branch information
paskal committed May 10, 2024
1 parent 30173d5 commit b54f753
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
10 changes: 9 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,20 @@ jobs:

- name: build and test
run: |
go test -v -timeout=100s -covermode=count -coverprofile=$GITHUB_WORKSPACE/profile.cov_tmp ./...
go test -race -v -timeout=100s -covermode=atomic -coverprofile=$GITHUB_WORKSPACE/profile.cov_tmp ./...
go build -race ./...
cat $GITHUB_WORKSPACE/profile.cov_tmp | grep -v "mocks" | grep -v "_mock" > $GITHUB_WORKSPACE/profile.cov
working-directory: app
env:
TZ: "America/Chicago"

- name: test examples
run: |
go test -race ./...
go build -race ./...
working-directory: examples/plugin
env:
TZ: "America/Chicago"

- name: golangci-lint
uses: golangci/golangci-lint-action@v6
Expand Down
2 changes: 0 additions & 2 deletions examples/plugin/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@ WORKDIR /build
RUN go build -o /build/plugin-example -ldflags "-X main.revision=${version} -s -w"


FROM ghcr.io/umputun/baseimage/app:v1.6.1 as base

FROM scratch

COPY --from=build /build/plugin-example /srv/plugin-example
Expand Down

0 comments on commit b54f753

Please sign in to comment.