mirror of
https://github.com/aljazceru/ark.git
synced 2026-02-02 01:54:41 +01:00
check go work sync in unit test (#268)
* check go work sync is ran * bump setup-go@v4 * remove go mod tidy
This commit is contained in:
35
.github/workflows/ark.unit.yaml
vendored
35
.github/workflows/ark.unit.yaml
vendored
@@ -14,6 +14,27 @@ on:
|
||||
- "pkg/client-sdk/**"
|
||||
|
||||
jobs:
|
||||
check-go-sync:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
- name: Set up Go
|
||||
uses: actions/setup-go@v4
|
||||
with:
|
||||
go-version: '>=1.22.6'
|
||||
|
||||
- name: Run go work sync
|
||||
run: go work sync
|
||||
|
||||
- name: Check for changes
|
||||
run: |
|
||||
if [[ -n $(git status --porcelain) ]]; then
|
||||
echo "Changes detected after running go work sync and go mod tidy"
|
||||
git diff
|
||||
exit 1
|
||||
fi
|
||||
|
||||
test-server:
|
||||
name: server unit tests
|
||||
runs-on: ubuntu-latest
|
||||
@@ -21,9 +42,9 @@ jobs:
|
||||
run:
|
||||
working-directory: ./server
|
||||
steps:
|
||||
- uses: actions/setup-go@v3
|
||||
- uses: actions/setup-go@v4
|
||||
with:
|
||||
go-version: ">1.17.2"
|
||||
go-version: '>=1.22.6'
|
||||
- uses: actions/checkout@v3
|
||||
- name: check linting
|
||||
uses: golangci/golangci-lint-action@v3
|
||||
@@ -33,7 +54,7 @@ jobs:
|
||||
- name: check code integrity
|
||||
uses: securego/gosec@master
|
||||
with:
|
||||
args: '-severity high -quiet ./...'
|
||||
args: "-severity high -quiet ./..."
|
||||
- run: go get -v -t -d ./...
|
||||
- name: unit testing
|
||||
run: make test
|
||||
@@ -45,9 +66,9 @@ jobs:
|
||||
run:
|
||||
working-directory: ./pkg/client-sdk
|
||||
steps:
|
||||
- uses: actions/setup-go@v3
|
||||
- uses: actions/setup-go@v4
|
||||
with:
|
||||
go-version: ">1.17.2"
|
||||
go-version: '>=1.22.6'
|
||||
- uses: actions/checkout@v3
|
||||
- name: check linting
|
||||
uses: golangci/golangci-lint-action@v3
|
||||
@@ -57,7 +78,7 @@ jobs:
|
||||
- name: check code integrity
|
||||
uses: securego/gosec@master
|
||||
with:
|
||||
args: '-severity high -quiet ./...'
|
||||
args: "-severity high -quiet ./..."
|
||||
- run: go get -v -t -d ./...
|
||||
- name: unit testing
|
||||
run: make test
|
||||
run: make test
|
||||
|
||||
@@ -43,7 +43,6 @@ require (
|
||||
github.com/oklog/ulid v1.3.1 // indirect
|
||||
github.com/opentracing/opentracing-go v1.2.0 // indirect
|
||||
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect
|
||||
github.com/rogpeppe/go-internal v1.12.0 // indirect
|
||||
github.com/vulpemventures/fastsha256 v0.0.0-20160815193821-637e65642941 // indirect
|
||||
go.mongodb.org/mongo-driver v1.14.0 // indirect
|
||||
go.opentelemetry.io/otel v1.28.0 // indirect
|
||||
|
||||
@@ -1,10 +1,6 @@
|
||||
github.com/aead/siphash v1.0.1/go.mod h1:Nywa3cDsYNNK3gaciGTWPwHt0wlpNV15vwmswBAUSII=
|
||||
github.com/ark-network/ark/api-spec v0.0.0-20240812230256-910716f72d1a h1:9Jt/77jO6tA6iWe1fuH7sm3M6NefKnBbOm277vapPfc=
|
||||
github.com/ark-network/ark/api-spec v0.0.0-20240812230256-910716f72d1a/go.mod h1:0B5seq/gzuGL8OZGUaO12yj73ZJKAde8L+nmLQAZ7IA=
|
||||
github.com/ark-network/ark/api-spec v0.0.0-20240815203029-edc4534dfc87 h1:VBY4KqHqxE4q6NnmvEZTLvLZoNA0Q6NhMhjBs1hzy9Y=
|
||||
github.com/ark-network/ark/api-spec v0.0.0-20240815203029-edc4534dfc87/go.mod h1:m5H86Dx+k8cQjLXeYL1MV+h3x/XnhJCXJP/PL3KgZqY=
|
||||
github.com/ark-network/ark/common v0.0.0-20240812230256-910716f72d1a h1:vjuHW6OF/dPV9CmwpqmWb+KmkdqNeksovhIRojRTpRE=
|
||||
github.com/ark-network/ark/common v0.0.0-20240812230256-910716f72d1a/go.mod h1:8DYeb06Dl8onmrV09xfsdDMGv5HoVtWoKhLBLXOYHew=
|
||||
github.com/ark-network/ark/common v0.0.0-20240815203029-edc4534dfc87 h1:TIv00zlpxLKmY2LjFAIMF8RxNtn9rFqQsv73Lwoj2ds=
|
||||
github.com/ark-network/ark/common v0.0.0-20240815203029-edc4534dfc87/go.mod h1:aYAGDfoeBLofnZt9n85wusFyCkrS7hvwdo5TynBlkuY=
|
||||
github.com/asaskevich/govalidator v0.0.0-20230301143203-a9d515a09cc2 h1:DklsrG3dyBCFEj5IhUbnKptjxatkF07cF2ak3yi77so=
|
||||
|
||||
Reference in New Issue
Block a user