From a2bd80c4f900d1819cf63dc97f878e4c4789aa74 Mon Sep 17 00:00:00 2001 From: George Ma Date: Mon, 18 Mar 2024 10:30:25 -0400 Subject: [PATCH] Temporarily rename the .ruby-version file to pass CI for rubocop-old MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Old versions of rubocop read the ruby version from .ruby-version first. We made the change upstream which is not captured in versions of rubocop (< 0.87). Upstream commit: https://github.com/rubocop/rubocop/commit/02b2c3a461f197134cb1d7e1bf693c4e3902e8de Co-authored-by: Étienne Barrié --- spec/erb_lint/linters/rubocop_spec.rb | 2 ++ 1 file changed, 2 insertions(+) diff --git a/spec/erb_lint/linters/rubocop_spec.rb b/spec/erb_lint/linters/rubocop_spec.rb index 9e8f13c8..ee0ad6c3 100644 --- a/spec/erb_lint/linters/rubocop_spec.rb +++ b/spec/erb_lint/linters/rubocop_spec.rb @@ -30,6 +30,8 @@ ) end before { linter.run(processed_source) } + before(:all) { File.rename(".ruby-version", ".ruby-version.bak") } + after(:all) { File.rename(".ruby-version.bak", ".ruby-version") } context "config is valid when rubocop_config is not explicitly provided" do let(:linter_config) do