diff --git a/.github/workflows/ci-build-and-install-gem.yml b/.github/workflows/ci-build-and-install-gem.yml index ac15492..e5ef1d3 100644 --- a/.github/workflows/ci-build-and-install-gem.yml +++ b/.github/workflows/ci-build-and-install-gem.yml @@ -6,16 +6,16 @@ on: jobs: build: - runs-on: ubuntu-22.04 + runs-on: ubuntu-latest steps: - name: Checkout code - uses: actions/checkout@v3 + uses: actions/checkout@v6 - name: Setup Ruby uses: ruby/setup-ruby@v1 with: - ruby-version: 3.1.2 + ruby-version: ruby - name: Build and install gem run: gem build *.gemspec && gem install *.gem diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 60c0913..6b58c53 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -6,7 +6,7 @@ on: jobs: build: - runs-on: ubuntu-22.04 + runs-on: ubuntu-latest strategy: fail-fast: false @@ -17,13 +17,15 @@ jobs: - { ruby: '3.0' } - { ruby: '3.1' } - { ruby: '3.2' } + - { ruby: '3.3' } + - { ruby: '3.4' } - { ruby: head, allow-failure: true } - - { ruby: jruby-9.3 } + - { ruby: jruby-10.0 } - { ruby: jruby-head, allow-failure: true } steps: - name: Checkout code - uses: actions/checkout@v3 + uses: actions/checkout@v6 - name: Setup Ruby ${{ matrix.ruby }} uses: ruby/setup-ruby@v1 diff --git a/spec/lib/twingly/public_suffix_list_spec.rb b/spec/lib/twingly/public_suffix_list_spec.rb index 48a2efd..5f7328a 100644 --- a/spec/lib/twingly/public_suffix_list_spec.rb +++ b/spec/lib/twingly/public_suffix_list_spec.rb @@ -24,7 +24,7 @@ let(:encoding) { Encoding::US_ASCII } # https://github.com/ruby/ruby/commit/571d21fd4a2e877f49b4ff918832bda9a5e8f91c let(:expected_error) do - if RUBY_VERSION >= "3.2.0" + if RUBY_VERSION >= "3.2.0" && RUBY_ENGINE != "jruby" Encoding::CompatibilityError else ArgumentError diff --git a/spec/lib/twingly/url_spec.rb b/spec/lib/twingly/url_spec.rb index 4cf899e..dba42d5 100644 --- a/spec/lib/twingly/url_spec.rb +++ b/spec/lib/twingly/url_spec.rb @@ -220,7 +220,7 @@ def leading_and_trailing_whitespace context "when called from the outside" do it "raises an error" do expect { described_class.internal_parse("a") }. - to raise_error(NoMethodError, /private method `internal_parse' called for/) + to raise_error(NoMethodError, /private method (`|')internal_parse' called for/) end end end @@ -229,7 +229,7 @@ def leading_and_trailing_whitespace context "when called from the outside" do it "raises an error" do expect { described_class.new("a", "b") }. - to raise_error(NoMethodError, /private method `new' called for/) + to raise_error(NoMethodError, /private method (`|')new' called for/) end end end diff --git a/twingly-url.gemspec b/twingly-url.gemspec index 25f333f..6e2e467 100644 --- a/twingly-url.gemspec +++ b/twingly-url.gemspec @@ -15,9 +15,9 @@ Gem::Specification.new do |s| s.required_ruby_version = ">= 2.6" s.add_dependency "addressable", "~> 2.6" - s.add_dependency "public_suffix", ">= 3.0.1", "< 6.0" + s.add_dependency "public_suffix", ">= 3.0.1", "< 8" - s.add_development_dependency "rake", "~> 12" + s.add_development_dependency "rake" s.add_development_dependency "rspec", "~> 3" s.add_development_dependency "pry", "~> 0"