diff --git a/.github/workflow/test.yml b/.github/workflow/test.yml new file mode 100644 index 0000000..ccc6aed --- /dev/null +++ b/.github/workflow/test.yml @@ -0,0 +1,32 @@ +# 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 + pull_request: + +jobs: + test: + name: Test with Ruby-${{ matrix.ruby }} + runs-on: ubuntu-latest + strategy: + matrix: + ruby-version: ['2.3', '2.4', '2.5', '2.6', '2.7', '3.0'] + + steps: + - uses: actions/checkout@v2 + - name: Set up Ruby + uses: ruby/setup-ruby@v1 + with: + ruby-version: ${{ matrix.ruby-version }} + bundler-cache: true + - name: Run tests + run: bundle exec rake test \ No newline at end of file diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 6fc74c3..0000000 --- a/.travis.yml +++ /dev/null @@ -1,16 +0,0 @@ -sudo: false -language: ruby -rvm: - - 2.3.4 - - 2.4.1 - - ruby-head - - jruby-9.1.7.0 - - jruby-head -jdk: - - oraclejdk8 -before_install: - - gem install bundler -matrix: - allow_failures: - - rvm: ruby-head - - rvm: jruby-head diff --git a/README.md b/README.md index 773eb1b..4ed7a2f 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,7 @@ [![Gem Version](https://badge.fury.io/rb/sinja.svg)](https://badge.fury.io/rb/sinja) [![Dependency Status](https://gemnasium.com/badges/github.com/mwpastore/sinja.svg)](https://gemnasium.com/github.com/mwpastore/sinja) -[![Build Status](https://travis-ci.org/mwpastore/sinja.svg?branch=master)](https://travis-ci.org/mwpastore/sinja) +[![Build Status](https://github.com/mwpastore/sinja/actions/workflows/test.yml/badge.svg)](https://github.com/mwpastore/sinja/actions) [![{json:api} version](https://img.shields.io/badge/%7Bjson%3Aapi%7D%20version-1.0-lightgrey.svg)][7] [![Chat in #sinja-rb on Gitter](https://badges.gitter.im/sinja-rb/Lobby.svg)](https://gitter.im/sinja-rb/Lobby) diff --git a/sinja.gemspec b/sinja.gemspec index a134cbb..7d81e69 100644 --- a/sinja.gemspec +++ b/sinja.gemspec @@ -43,14 +43,11 @@ Gem::Specification.new do |spec| spec.add_dependency 'sinatra', '~> 2.0' spec.add_dependency 'sinatra-contrib', '~> 2.0' - spec.add_development_dependency 'bundler', '~> 1.11' spec.add_development_dependency 'jdbc-sqlite3', '~> 3.8' if defined?(JRUBY_VERSION) spec.add_development_dependency 'minitest', '~> 5.9' spec.add_development_dependency 'minitest-hooks', '~> 1.4' - #spec.add_development_dependency 'munson', '~> 0.4' # in Gemfile spec.add_development_dependency 'rack-test', '~> 0.7.0' spec.add_development_dependency 'rake', '~> 12.0' spec.add_development_dependency 'sequel', '>= 4.49', '< 6' - #spec.add_development_dependency 'sinja-sequel', '~> 0.1' # in Gemfile spec.add_development_dependency 'sqlite3', '~> 1.3' if !defined?(JRUBY_VERSION) end