diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml new file mode 100644 index 0000000..ac94c4a --- /dev/null +++ b/.github/workflows/tests.yml @@ -0,0 +1,24 @@ +# This workflow runs tests for go-nekos-api +# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-go + +name: tests + +on: + push: + branches: [ "main" ] + pull_request: + branches: [ "main" ] + +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + - name: Set up Go + uses: actions/setup-go@v4 + with: + go-version: '1.18' + + - name: Run tests + run: go test github.com/generalvamp/go-nekos-api/... -v \ No newline at end of file diff --git a/README.md b/README.md index 5c9f558..33d8277 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,6 @@ # go-nekos-api +[![tests](https://github.com/generalvamp/go-nekos-api/actions/workflows/tests.yml/badge.svg)](https://github.com/generalvamp/go-nekos-api/actions/workflows/tests.yml) + + Unofficial go wrapper of [Nekos API](https://github.com/Nekos-API/Nekos-API) \ No newline at end of file