From d74e88caccd94c0e6cdaeaf2cf9ce6aa5b0ae742 Mon Sep 17 00:00:00 2001 From: Daniel Vandersluis Date: Fri, 24 Jan 2025 12:09:55 -0500 Subject: [PATCH] Replace travisCI with GH actions --- .github/workflows/test.yml | 35 +++++++++++++++++++++++++++++++++++ .travis.yml | 22 ---------------------- 2 files changed, 35 insertions(+), 22 deletions(-) create mode 100644 .github/workflows/test.yml delete mode 100644 .travis.yml diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml new file mode 100644 index 0000000..1e99a6c --- /dev/null +++ b/.github/workflows/test.yml @@ -0,0 +1,35 @@ +# This workflow uses actions that are not certified by GitHub. +# They are provided by a third-party and are governed by +# separate terms of service, privacy policy, and support +# documentation. +# This workflow will download a prebuilt Ruby version, install dependencies and run tests with Rake +# For more information see: https://github.com/marketplace/actions/setup-ruby-jruby-and-truffleruby + +name: Ruby + +on: + push: + branches: [ "master", "v1.0" ] + pull_request: + branches: [ "master" ] + +permissions: + contents: read + +jobs: + test: + + runs-on: ubuntu-latest + strategy: + matrix: + ruby-version: ['2.7', '3.0', '3.1', '3.2', '3.3', '3.4', 'head'] + + steps: + - uses: actions/checkout@v4 + - name: Set up Ruby + uses: ruby/setup-ruby@v1 + with: + ruby-version: ${{ matrix.ruby-version }} + bundler-cache: true # runs 'bundle install' and caches installed gems automatically + - name: Run tests + run: bundle exec rspec diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 0d1f97c..0000000 --- a/.travis.yml +++ /dev/null @@ -1,22 +0,0 @@ ---- -os: linux -language: ruby -cache: bundler -rvm: - - 2.6.5 - - 2.5.7 - - 2.4.9 - - 2.7.0-preview2 -before_install: gem install bundler -v 2.0.1 - -jobs: - include: - - stage: lint - rvm: 2.6.5 - script: bundle exec rubocop - allow_failures: - - rvm: 2.7.0.preview2 - -stages: - - lint - - test