Skip to content

build-and-test

build-and-test #328

Workflow file for this run

name: build-and-test
on:
push:
schedule:
- cron: "0 0 * * 1"
jobs:
unit-tests:
name: "Puppet ${{ matrix.puppet-version }} Unit Tests"
runs-on: ubuntu-latest
strategy:
matrix:
include:
- ruby-version: 2.7
puppet-version: 6
- ruby-version: 3.1
puppet-version: 7
steps:
- uses: actions/checkout@v4
- uses: ruby/setup-ruby@v1
with:
ruby-version: ${{matrix.ruby-version}}
- run: bundle install
env:
PUPPET_VERSION: "~> ${{ matrix.puppet-version }}"
- run: bundle exec rake test
env:
PUPPET_VERSION: "~> ${{ matrix.puppet-version }}"
SPEC_OPTS: '--format documentation'
RUBYOPT: "-W0"
acceptance-tests:
name: "${{ matrix.label }} Acceptance Tests"
runs-on: ubuntu-latest
strategy:
matrix:
include:
- beaker-set: debian-10-64
label: "Debian 10"
- beaker-set: default
label: "Debian 11"
- beaker-set: ubuntu-2004-64
label: "Ubuntu 20.04"
- beaker-set: ubuntu-2204-64
label: "Ubuntu 22.04"
steps:
- uses: docker/login-action@v3.1.0
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- uses: actions/checkout@v4
- uses: ruby/setup-ruby@v1
- run: bundle install
- run: bundle exec rake beaker