Skip to content

Commit ab34ca8

Browse files
authored
Merge pull request #590 from zendesk/jury.razumau/modernise_workflows
drop support for Ruby 2.7 and 3.0, update CI
2 parents 45a9ca3 + 911e887 commit ab34ca8

31 files changed

+476
-306
lines changed

.github/workflows/main.yml

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -5,34 +5,33 @@ on:
55
pull_request:
66
push:
77
branches:
8-
- master
8+
- main
99
- spec_live
1010

1111
jobs:
1212
test-and-lint:
1313
name: Test and lint
1414
runs-on: ubuntu-latest
1515
strategy:
16+
fail-fast: false
1617
matrix:
1718
ruby:
18-
- "2.7"
19-
- "3.0"
2019
- "3.1"
2120
- "3.2"
2221
- "3.3"
2322
- "3.4"
2423
- "jruby-9.4"
24+
- "jruby-10.0"
2525
steps:
2626
- name: Checkout code
27-
uses: zendesk/checkout@v2
27+
uses: actions/checkout@v5
2828
- name: Set up Ruby
29-
uses: zendesk/setup-ruby@v1
29+
uses: ruby/setup-ruby@v1
3030
with:
3131
bundler-cache: true
3232
ruby-version: ${{ matrix.ruby }}
3333
- name: Test and Lint
3434
run: |
35-
bundle install
3635
bundle exec rake
3736
bundle exec rubocop
3837
spec-live:
@@ -45,15 +44,13 @@ jobs:
4544
runs-on: ubuntu-latest
4645
steps:
4746
- name: Checkout code
48-
uses: zendesk/checkout@v2
47+
uses: actions/checkout@v5
4948
- name: Set up Ruby
50-
uses: zendesk/setup-ruby@v1
49+
uses: ruby/setup-ruby@v1
5150
with:
5251
bundler-cache: true
53-
ruby-version: 3.1
5452
- name: spec:live
5553
run: |
56-
bundle install
5754
bundle exec rake clean_live set_ci_credentials spec:live ||
5855
bundle exec rake clean_live &&
5956
bundle exec rspec spec/live --only-failures

.github/workflows/publish.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515
id-token: write
1616
contents: write
1717
steps:
18-
- uses: actions/checkout@v4
18+
- uses: actions/checkout@v5
1919
- name: Set up Ruby
2020
uses: ruby/setup-ruby@v1
2121
with:

.gitignore

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,5 @@ spec/fixtures/cassettes
44
spec/fixtures/credentials.yml
55
coverage/**
66
.yardoc/**
7-
Gemfile.lock
8-
.ruby-version
97
vendor/bundle/**
108
pkg/**

.rspec

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
11
--color
2+
--order random

.rubocop.yml

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,15 @@
11
inherit_from: .rubocop_todo.yml
22

33
AllCops:
4-
TargetRubyVersion: 2.7
4+
TargetRubyVersion: 3.1
55
DisplayCopNames: true
6+
SuggestExtensions: false
7+
NewCops: enable
68
Exclude:
79
- .git/**/*
810
- spec/core/middleware/response/sanitize_response_spec.rb
911
- vendor/**/*
1012

11-
# Prevents Ruby 3.1 incompatibility error. You can enable this cop when Ruby 2.7 support is dropped.
12-
# See https://github.com/rubocop/rubocop/issues/10258
13-
Layout/BlockAlignment:
14-
Enabled: false
15-
1613
# Align ends correctly.
1714
Layout/EndAlignment:
1815
EnforcedStyleAlignWith: variable
@@ -46,3 +43,16 @@ Metrics:
4643

4744
Style/DoubleNegation:
4845
Enabled: false
46+
47+
Style/OptionalBooleanParameter:
48+
Enabled: false
49+
50+
Naming/PredicateMethod:
51+
Enabled: false
52+
53+
Style/HashEachMethods:
54+
Enabled: false
55+
56+
Style/RedundantFetchBlock:
57+
Exclude:
58+
- spec/core/lru_cache_spec.rb

0 commit comments

Comments
 (0)