Skip to content

Commit

Permalink
cicd: test on pull requests.
Browse files Browse the repository at this point in the history
  • Loading branch information
arshamalh committed Nov 24, 2023
1 parent 0433c36 commit 0230cae
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 1 deletion.
31 changes: 31 additions & 0 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Go Test

on:
pull_request:
branches:
- main

jobs:
test:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v2

- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.21.0

- name: Install dependencies
run: go mod download

- name: Run tests
run: go test -v ./...

- name: Check code style
run: gofmt -l -s $(find . -type f -name '*.go' -not -path "./vendor/*")

- name: Check for security issues
run: gosec ./...
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/arshamalh/dockeroller

go 1.19
go 1.21.0

require (
github.com/docker/docker v20.10.17+incompatible
Expand Down

0 comments on commit 0230cae

Please sign in to comment.