Bump github.com/rabbitmq/amqp091-go from 1.8.1 to 1.9.0 #48
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Go | |
on: [push] | |
jobs: | |
test: | |
strategy: | |
matrix: | |
go-version: [1.16.x, 1.17.x, 1.18.x, 1.19.x] | |
runs-on: ubuntu-latest | |
services: | |
rabbitmq: | |
image: rabbitmq:latest | |
ports: | |
- 5672:5672 | |
# needed because the rabbitmq container does not provide a healthcheck | |
options: --health-cmd "rabbitmqctl node_health_check" --health-interval 10s --health-timeout 5s --health-retries 5 | |
steps: | |
- name: Install Go | |
uses: actions/setup-go@v2 | |
with: | |
go-version: ${{ matrix.go-version }} | |
- name: Checkout | |
uses: actions/checkout@v2 | |
with: | |
# Disabling shallow clone is recommended for improving relevancy of reporting | |
fetch-depth: 0 | |
- name: Get deps | |
run: go get ./... | |
- name: Linter | |
run: | | |
gofmt -d -s . | |
go vet *.go | |
- name: Tests with real broker | |
run: | | |
go test -v -race -coverprofile=coverage.txt -covermode=atomic -mock-broker=0 | |
bash <(curl -s https://codecov.io/bash) || true | |
- name: Tests with mocked broker | |
run: | | |
go test -v -race -mock-broker=1 | |
bash <(curl -s https://codecov.io/bash) || true | |
sonar: | |
runs-on: ubuntu-latest | |
steps: | |
- name: SonarCloud Scan | |
uses: sonarsource/sonarcloud-github-action@master | |
with: | |
args: > | |
-Dsonar.organization=cheshir | |
-Dsonar.projectKey=cheshir_go-mq | |
-Dsonar.sources=. | |
-Dsonar.exclusions=**/*_test.go | |
-Dsonar.tests=. | |
-Dsonar.test.inclusions=**/*_test.go | |
-Dsonar.go.coverage.reportPaths=coverage.txt | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} |