diff --git a/CHANGELOG.md b/CHANGELOG.md index fba9a66..406154e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,10 @@ ## Unreleased +## 3.5.0 - 2023-12-28 + * Change: update Faraday to 2.x, released about two years ago. The public API of this gem doesn't change, therefore this is not a major release. However, if you manipulate directly faraday's objects, you may encounter breaking changes. Refer to [Faraday's website](https://lostisland.github.io/faraday/) for how to migrate. +* Compat: drop support for Ruby < 3. The lib is still expected to work for the time being. +* Compat: include Ruby 3.3 in the test matrix ## 3.4.0 - 2023-01-26 diff --git a/lib/scalingo/version.rb b/lib/scalingo/version.rb index 1bb7698..59f5d7b 100644 --- a/lib/scalingo/version.rb +++ b/lib/scalingo/version.rb @@ -1,3 +1,3 @@ module Scalingo - VERSION = "3.4.0" + VERSION = "3.5.0" end diff --git a/spec/scalingo/auth/tokens_spec.rb b/spec/scalingo/auth/tokens_spec.rb index 4341323..fa64a88 100644 --- a/spec/scalingo/auth/tokens_spec.rb +++ b/spec/scalingo/auth/tokens_spec.rb @@ -8,7 +8,7 @@ let(:arguments) { meta[:exchange][:valid] } let(:stub_pattern) { "exchange-200" } - it "should be successful" do + it "is successful" do expect(response).to be_successful expect(response.data[:token]).to be_present end @@ -18,7 +18,7 @@ let(:arguments) { meta[:exchange][:invalid] } let(:stub_pattern) { "exchange-401" } - it "should be rejected with an valid token" do + it "is rejected with an valid token" do expect(response.status).to eq 401 end end diff --git a/spec/support/shared.rb b/spec/support/shared.rb index 394a5fc..1c4428a 100644 --- a/spec/support/shared.rb +++ b/spec/support/shared.rb @@ -2,7 +2,7 @@ let(:expected_code) { code } let(:custom_headers) { {"X-Custom-Header" => "custom"} } - it "should be successful" do + it "is successful" do expect(response).to be_successful expect(response.status).to eq code end @@ -66,7 +66,7 @@ let(:expected_type) { Object } unless method_defined?(:expected_type) let(:expected_keys) { %i[id] } unless method_defined?(:expected_keys) - it "should be an object of the expected type (and if applicable, the expected keys)" do + it "is an object of the expected type (and if applicable, the expected keys)" do expect(response.data).to be_a_kind_of(expected_type) if response.data.respond_to?(:key?) @@ -80,7 +80,7 @@ RSpec.shared_examples "an empty response" do |code = 204| it_behaves_like "a successful response", code - it "should be empty" do + it "is empty" do expect(response.data).to eq("") end end @@ -92,15 +92,15 @@ let(:expected_type) { Object } unless method_defined?(:expected_type) let(:expected_keys) { %i[id] } unless method_defined?(:expected_keys) - it "should be an array" do + it "is an array" do expect(response.data).to be_a_kind_of(Array) end - it "should have the number of expected elements" do + it "contains the number of expected elements" do expect(response.data.size).to eq(expected_count) end - it "items should be of the expected type (and if applicable, the expected keys)" do + it "items are of the expected type (and if applicable, the expected keys)" do response.data.each do |item| expect(item).to be_a_kind_of(expected_type) @@ -114,16 +114,13 @@ end RSpec.shared_examples "a paginated collection" do |code = 200| - it "should be paginated" do + it "is paginated" do expect(response).to be_paginated end end RSpec.shared_examples "a non-paginated collection" do |code = 200| - it "should not be paginated" do + it "is not paginated" do expect(response).not_to be_paginated end end - -RSpec.shared_examples "a method with a configurable request" do -end