mirror of
https://github.com/hashicorp/vagrant.git
synced 2026-05-28 04:36:05 -04:00
46 lines
1.1 KiB
YAML
46 lines
1.1 KiB
YAML
name: Vagrant Go unit tests
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
- 'test-*'
|
|
paths:
|
|
- 'builtin/**'
|
|
- 'cmd/**'
|
|
- 'internal/**'
|
|
- '.github/workflows**'
|
|
- 'go.mod'
|
|
- 'go.sum'
|
|
pull_request:
|
|
branches:
|
|
- main
|
|
paths:
|
|
- 'builtin/**'
|
|
- 'cmd/**'
|
|
- 'internal/**'
|
|
- 'go.mod'
|
|
- 'go.sum'
|
|
|
|
jobs:
|
|
unit-tests-go:
|
|
runs-on: ubuntu-latest
|
|
strategy:
|
|
matrix:
|
|
ruby: ['3.0', '3.1', '3.2', '3.3']
|
|
name: Vagrant unit tests on Go (Ruby ${{ matrix.ruby }})
|
|
steps:
|
|
- name: Code Checkout
|
|
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
|
|
- name: Setup Go
|
|
uses: actions/setup-go@cdcb36043654635271a94b9a6d1392de5bb323a7 # v5.0.1
|
|
with:
|
|
go-version-file: go.mod
|
|
- name: Setup Ruby
|
|
uses: ruby/setup-ruby@3783f195e29b74ae398d7caca108814bbafde90e # v1.180.1
|
|
with:
|
|
ruby-version: ${{matrix.ruby}}
|
|
bundler-cache: true
|
|
- name: Vet
|
|
run: go vet -mod=mod ./...
|
|
- name: Test
|
|
run: go test -mod=mod ./...
|