make github action #27
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 Test CI | |
on: | |
push: | |
branches: | |
- main # Run tests on pushes to the main branch | |
pull_request: | |
branches: | |
- main # Run tests for pull requests targeting the main branch | |
jobs: | |
test: | |
name: Run Go Tests | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Set up Go | |
uses: actions/setup-go@v4 | |
with: | |
go-version: 1.22 # Replace with the Go version you're using | |
- name: Install dependencies | |
run: make build | |
- name: Run tests | |
run: make test |