From e6795bedd7367c66ec81cf54b5813ed05ec84696 Mon Sep 17 00:00:00 2001 From: Jennifer Konikowski Date: Mon, 3 May 2021 13:29:43 -0400 Subject: [PATCH] run tests on 2.5 since support for 2.4 was dropped --- .github/workflows/test.yml | 2 +- test/standard/builds_config_test.rb | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 50a52195..44caf8a5 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -12,7 +12,7 @@ jobs: strategy: matrix: os: [ ubuntu-latest ] - ruby-version: [2.4, 2.7, 3.0] + ruby-version: [2.5, 2.7, 3.0] runs-on: ${{ matrix.os }} diff --git a/test/standard/builds_config_test.rb b/test/standard/builds_config_test.rb index 4644f76f..0a773576 100644 --- a/test/standard/builds_config_test.rb +++ b/test/standard/builds_config_test.rb @@ -124,8 +124,8 @@ def config_store(config_root = nil, rubocop_yml = highest_compatible_yml_version def highest_compatible_yml_version non_latest_ruby = Dir["config/*.yml"] .map { |n| n.match(/ruby-(.*)\.yml/) }.compact - .map { |m| Gem::Version.new(m[1]) }.sort - .find { |v| Gem::Version.new(RUBY_VERSION) < v } + .map { |m| Gem::Version.new(m[1]) }.sort.reverse + .find { |v| Gem::Version.new(RUBY_VERSION) > v } if non_latest_ruby "config/ruby-#{non_latest_ruby}.yml"