1234567891011121314151617181920212223242526272829303132333435363738 |
- name: Run test cases
- on:
- push:
- pull_request:
- release:
- types:
- - published
- jobs:
- run_test_case:
- runs-on: ubuntu-latest
- container:
- image: golang:1.14
- steps:
- - uses: actions/checkout@v2
- - name: run code static check
- run : |
- if [ ! -z "$(gofmt -l .)" ];then
- echo "code static check error"
- gofmt -l .
- exit 1
- fi
- - name: install lib
- run: apt-get update && apt-get install libzmq3-dev -y
- - name: run test case
- run: |
- mkdir -p data
- mkdir -p log
- go build --buildmode=plugin -o plugins/sources/Random@v1.0.0.so plugins/sources/random.go
- go build --buildmode=plugin -o plugins/sinks/File@v1.0.0.so plugins/sinks/file.go
- go build --buildmode=plugin -o plugins/functions/Echo.so plugins/functions/echo.go
- go build --buildmode=plugin -o plugins/functions/CountPlusOne@v1.0.0.so plugins/functions/countPlusOne.go
- go test ./...
- go test --tags=edgex ./...
-
|