Skip to content

Commit

Permalink
Convert from Travis CI to GitHub Actions
Browse files Browse the repository at this point in the history
  • Loading branch information
ekohl committed Mar 11, 2022
1 parent 09ce246 commit f986fc9
Show file tree
Hide file tree
Showing 4 changed files with 61 additions and 47 deletions.
57 changes: 57 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
name: Test

on:
pull_request: {}
push:
branches: master

env:
BUNDLE_WITHOUT: development:release

jobs:
test:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
ruby:
- "3.1"
- "3.0"
- "2.7"
- "2.6"
- "2.5"
- "2.4"
puppet:
- "~> 5.5.10"
- "~> 6.5"
- "~> 7.0"
- "https://github.com/puppetlabs/puppet.git#main"
exclude:
- ruby: "3.1"
puppet: "~> 5.5.10"
- ruby: "3.0"
puppet: "~> 5.5.10"
- ruby: "2.6"
puppet: "~> 7.0"
- ruby: "2.5"
puppet: "~> 7.0"
- ruby: "2.4"
puppet: "~> 7.0"
- ruby: "2.6"
puppet: "https://github.com/puppetlabs/puppet.git#main"
- ruby: "2.5"
puppet: "https://github.com/puppetlabs/puppet.git#main"
- ruby: "2.4"
puppet: "https://github.com/puppetlabs/puppet.git#main"
name: "Ruby ${{ matrix.ruby }} - Puppet ${{ matrix.puppet }}"
env:
PUPPET_VERSION: ${{ matrix.puppet }}
steps:
- uses: actions/checkout@v3
- name: Install Ruby ${{ matrix.ruby }}
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
bundler-cache: true
- name: Run tests
run: bundle exec rake
43 changes: 0 additions & 43 deletions .travis.yml

This file was deleted.

4 changes: 2 additions & 2 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,12 @@ gemspec

# Override gemspec for CI matrix builds.
# But only if the environment variable is set
gem 'puppet', *location_for(ENV['PUPPET_VERSION'] || '>= 5') if ENV['PUPPET_VERSION']
gem 'puppet', *location_for(ENV['PUPPET_VERSION']) if ENV['PUPPET_VERSION']

group :test do
gem 'rspec'
end

group :release do
gem 'github_changelog_generator', :require => false, :git => 'https://github.com/github-changelog-generator/github-changelog-generator'
gem 'github_changelog_generator', require: false
end
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[![Build Status](https://travis-ci.org/voxpupuli/puppet-syntax.svg?branch=master)](https://travis-ci.org/voxpupuli/puppet-syntax)
TODO: [![Build Status](https://travis-ci.org/voxpupuli/puppet-syntax.svg?branch=master)](https://travis-ci.org/voxpupuli/puppet-syntax)
[![Gem Version](https://img.shields.io/gem/v/puppet-syntax.svg)](https://rubygems.org/gems/puppet-syntax)
[![Gem Downloads](https://img.shields.io/gem/dt/puppet-syntax.svg)](https://rubygems.org/gems/puppet-syntax)

Expand All @@ -14,7 +14,7 @@ Puppet::Syntax is supported with:
- Puppet >= 5.0 that provides the `validate` face.
- Ruby >= 2.4

For the specific versions that we test against, see the [TravisCI config](.travis.yml).
For the specific versions that we test against, see the [GitHub Actions workflow](.github/workflows/test.yml).

## Installation

Expand Down

0 comments on commit f986fc9

Please sign in to comment.