From f015b62d4e15714299db07e487cee43b252d6f87 Mon Sep 17 00:00:00 2001 From: Ben Thorner Date: Fri, 15 Mar 2019 16:25:32 +0000 Subject: [PATCH 1/2] Fix tests to work with Ruby 2.6 A new version of Webmock is required to work with the new version of Ruby. --- gds-api-adapters.gemspec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gds-api-adapters.gemspec b/gds-api-adapters.gemspec index 05ef4bf9..7bfe4f65 100644 --- a/gds-api-adapters.gemspec +++ b/gds-api-adapters.gemspec @@ -42,7 +42,7 @@ Gem::Specification.new do |s| s.add_development_dependency 'simplecov', '~> 0.16' s.add_development_dependency 'simplecov-rcov' s.add_development_dependency 'timecop', '~> 0.9' - s.add_development_dependency 'webmock', '~> 3.3' + s.add_development_dependency 'webmock', '~> 3.5' s.add_development_dependency 'webrick', '~> 1.4' s.add_development_dependency 'yard', '~> 0.9' end From 0792575e3c8da5f180b0763eb9f1ff144302eb2c Mon Sep 17 00:00:00 2001 From: Ben Thorner Date: Fri, 15 Mar 2019 16:26:05 +0000 Subject: [PATCH 2/2] Remove pointless warnings when running tests This removes warnings that were complicating the test output. All of the warnings were about other gems, except for one minor deprecation. --- Rakefile | 2 +- test/test_helper.rb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Rakefile b/Rakefile index e9c78892..4a969f3c 100644 --- a/Rakefile +++ b/Rakefile @@ -11,7 +11,7 @@ end Rake::TestTask.new("test") do |t| t.libs << "test" t.test_files = FileList["test/**/*_test.rb"] - t.verbose = true + t.warning = false end task default: :test diff --git a/test/test_helper.rb b/test/test_helper.rb index 95001ac4..17f3f850 100644 --- a/test/test_helper.rb +++ b/test/test_helper.rb @@ -14,7 +14,7 @@ require 'minitest/around' require 'rack/utils' require 'rack/test' -require 'mocha/mini_test' +require 'mocha/minitest' require 'timecop' require 'gds-api-adapters' require 'govuk-content-schema-test-helpers'