mirror of
https://github.com/AthanorLabs/atomic-swap.git
synced 2026-01-10 06:38:04 -05:00
New bash library, and well as bash linting and formatting (#170)
* Allows unit and integration tests to share the same bash code via a utility library named testlib.sh. * Linting and formatting of bash scripts was added to the Makefile targets lint and format. * Updated the docker image and Go used by git actions
This commit is contained in:
12
.github/workflows/checks.yml
vendored
12
.github/workflows/checks.yml
vendored
@@ -10,9 +10,9 @@ name: checks
|
||||
|
||||
jobs:
|
||||
linter-check:
|
||||
runs-on: ubuntu-latest
|
||||
runs-on: ubuntu-22.04
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
- name: Run go fmt
|
||||
run: diff -u <(echo -n) <(gofmt -d -s .)
|
||||
@@ -21,12 +21,12 @@ jobs:
|
||||
run: make lint
|
||||
|
||||
vet-check:
|
||||
runs-on: ubuntu-latest
|
||||
runs-on: ubuntu-22.04
|
||||
steps:
|
||||
- uses: actions/setup-go@v2
|
||||
- uses: actions/setup-go@v3
|
||||
with:
|
||||
go-version: '1.17.x'
|
||||
- uses: actions/checkout@v2
|
||||
go-version: '1.18.x'
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
- name: Run go vet
|
||||
run: |
|
||||
|
||||
12
.github/workflows/integration-tests.yaml
vendored
12
.github/workflows/integration-tests.yaml
vendored
@@ -10,9 +10,9 @@ jobs:
|
||||
integration-tests:
|
||||
strategy:
|
||||
matrix:
|
||||
go-version: [1.17.x]
|
||||
go-version: [1.18.x]
|
||||
node-version: [16.x]
|
||||
platform: [ubuntu-latest]
|
||||
platform: [ubuntu-22.04]
|
||||
runs-on: ${{ matrix.platform }}
|
||||
steps:
|
||||
- id: go-cache-paths
|
||||
@@ -20,14 +20,14 @@ jobs:
|
||||
echo "::set-output name=go-build::$(go env GOCACHE)"
|
||||
echo "::set-output name=go-mod::$(go env GOMODCACHE)"
|
||||
|
||||
- uses: actions/setup-go@v2
|
||||
- uses: actions/setup-go@v3
|
||||
with:
|
||||
go-version: ${{ matrix.go-version }}
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
# cache go build cache
|
||||
- name: Cache go modules
|
||||
uses: actions/cache@v2
|
||||
uses: actions/cache@v3
|
||||
with:
|
||||
path: ${{ steps.go-cache-paths.outputs.go-build }}
|
||||
key: ${{ runner.os }}-go-build-${{ hashFiles('**/go.sum') }}
|
||||
@@ -35,7 +35,7 @@ jobs:
|
||||
|
||||
# cache go mod cache
|
||||
- name: Cache go modules
|
||||
uses: actions/cache@v2
|
||||
uses: actions/cache@v3
|
||||
with:
|
||||
path: ${{ steps.go-cache-paths.outputs.go-mod }}
|
||||
key: ${{ runner.os }}-go-mod-${{ hashFiles('**/go.sum') }}
|
||||
|
||||
12
.github/workflows/unit-tests.yml
vendored
12
.github/workflows/unit-tests.yml
vendored
@@ -10,9 +10,9 @@ jobs:
|
||||
unit-tests:
|
||||
strategy:
|
||||
matrix:
|
||||
go-version: [1.17.x]
|
||||
go-version: [1.18.x]
|
||||
node-version: [16.x]
|
||||
platform: [ubuntu-latest]
|
||||
platform: [ubuntu-22.04]
|
||||
runs-on: ${{ matrix.platform }}
|
||||
steps:
|
||||
- id: go-cache-paths
|
||||
@@ -20,14 +20,14 @@ jobs:
|
||||
echo "::set-output name=go-build::$(go env GOCACHE)"
|
||||
echo "::set-output name=go-mod::$(go env GOMODCACHE)"
|
||||
|
||||
- uses: actions/setup-go@v2
|
||||
- uses: actions/setup-go@v3
|
||||
with:
|
||||
go-version: ${{ matrix.go-version }}
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
# cache go build cache
|
||||
- name: Cache go modules
|
||||
uses: actions/cache@v2
|
||||
uses: actions/cache@v3
|
||||
with:
|
||||
path: ${{ steps.go-cache-paths.outputs.go-build }}
|
||||
key: ${{ runner.os }}-go-build-${{ hashFiles('**/go.sum') }}
|
||||
@@ -35,7 +35,7 @@ jobs:
|
||||
|
||||
# cache go mod cache
|
||||
- name: Cache go modules
|
||||
uses: actions/cache@v2
|
||||
uses: actions/cache@v3
|
||||
with:
|
||||
path: ${{ steps.go-cache-paths.outputs.go-mod }}
|
||||
key: ${{ runner.os }}-go-mod-${{ hashFiles('**/go.sum') }}
|
||||
|
||||
Reference in New Issue
Block a user