Skip to content

Commit

Permalink
Add Ruby 2.7 test support
Browse files Browse the repository at this point in the history
  • Loading branch information
splittingred committed Jun 15, 2020
1 parent 1a7f9a4 commit f157736
Show file tree
Hide file tree
Showing 3 changed files with 45 additions and 5 deletions.
31 changes: 27 additions & 4 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,19 +18,25 @@ executors:
parameters:
ruby-version:
type: string
default: "2.4.6"
default: "2.4.9"
ruby_2_5:
<<: *ruby_env
parameters:
ruby-version:
type: string
default: "2.5.5"
default: "2.5.8"
ruby_2_6:
<<: *ruby_env
parameters:
ruby-version:
type: string
default: "2.6.3"
default: "2.6.6"
ruby_2_7:
<<: *ruby_env
parameters:
ruby-version:
type: string
default: "2.7.1"

commands:
pre-setup:
Expand All @@ -39,12 +45,18 @@ commands:
- checkout
bundle-install:
steps:
- run:
name: "Install bundler 1.17.3"
command: |
echo 'export BUNDLER_VERSION=1.17.3' >> $BASH_ENV
source $BASH_ENV
gem install bundler:1.17.3
- restore_cache:
keys:
- gem-cache-{{ arch }}-{{ .Branch }}-{{ checksum "Gemfile.lock" }}
- gem-cache-{{ arch }}-{{ .Branch }}
- gem-cache
- run: bundle check || bundle install --path vendor/bundle
- run: bundle check --path vendor/bundle || bundle install --path vendor/bundle
- save_cache:
key: gem-cache-{{ arch }}-{{ .Branch }}-{{ checksum "Gemfile.lock" }}
paths:
Expand Down Expand Up @@ -144,3 +156,14 @@ workflows:
- rspec-unit:
name: "ruby-2_6-rspec"
e: "ruby_2_6"
ruby_2_7:
jobs:
- bundle-audit:
name: "ruby-2_7-bundle_audit"
e: "ruby_2_7"
- rubocop:
name: "ruby-2_7-rubocop"
e: "ruby_2_7"
- rspec-unit:
name: "ruby-2_7-rspec"
e: "ruby_2_7"
10 changes: 9 additions & 1 deletion gruf.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,14 @@ Gem::Specification.new do |spec|
spec.required_ruby_version = '~> 2.4'

spec.add_development_dependency 'bundler', '~> 1.11'
spec.add_development_dependency 'bundler-audit', '>= 0.6'
spec.add_development_dependency 'rake', '>= 10.0'
spec.add_development_dependency 'pry', '~> 0.11'
spec.add_development_dependency 'null-logger', '>= 0.1'
spec.add_development_dependency 'pry', '~> 0.12'
spec.add_development_dependency 'rspec', '>= 3.8'
spec.add_development_dependency 'rspec_junit_formatter', '>= 0.4'
spec.add_development_dependency 'rubocop', '>= 0.68'
spec.add_development_dependency 'simplecov', '>= 0.16'

spec.add_runtime_dependency 'grpc', '~> 1.10'
spec.add_runtime_dependency 'grpc-tools', '~> 1.10'
Expand All @@ -46,4 +52,6 @@ Gem::Specification.new do |spec|

spec.add_runtime_dependency 'concurrent-ruby', '> 1'
spec.add_runtime_dependency 'slop', '~> 4.6'
spec.add_runtime_dependency 'thwait', '~> 0.1'
spec.add_runtime_dependency 'e2mmap', '~> 0.1'
end
9 changes: 9 additions & 0 deletions script/test
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#!/usr/bin/env bash

set -eou pipefail

bundle install
bundle exec bundle-audit update
bundle exec bundle-audit check -v
bundle exec rubocop -P -c ./.rubocop.yml
bundle exec rspec

0 comments on commit f157736

Please sign in to comment.