diff --git a/Dockerfile b/Dockerfile index b20c11632..da37d574e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM phusion/passenger-full:1.0.5 +FROM phusion/passenger-full:0.9.30 LABEL maintainer="kgarza@datacite.org" # Set correct environment variables. @@ -10,6 +10,9 @@ RUN usermod -a -G docker_env app # Use baseimage-docker's init process. CMD ["/sbin/my_init"] +# Install Ruby 2.4.4 +RUN bash -lc 'rvm --default use ruby-2.4.4' + # Update installed APT packages RUN apt-get update && apt-get upgrade -y -o Dpkg::Options::="--force-confold" && \ apt-get install ntp wget tzdata pandoc -y && \ diff --git a/Gemfile b/Gemfile index d2e8aaceb..3074534d5 100644 --- a/Gemfile +++ b/Gemfile @@ -62,7 +62,7 @@ gem 'graphql-errors', '~> 0.3.0' # gem 'graphql-cache', '~> 0.6.0' group :development, :test do - gem 'rspec-rails', '~> 3.5', '>= 3.5.2' + gem 'rspec-rails', '~> 3.8', '>= 3.8.2' gem 'rspec-benchmark', '~> 0.4.0' gem 'rubocop', '~> 0.68.1', require: false gem 'rubocop-performance', '~> 1.2', require: false diff --git a/Gemfile.lock b/Gemfile.lock index 0c258aeb9..b0d4c09f8 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -582,7 +582,7 @@ DEPENDENCIES rails (~> 5.2.0) rake (~> 12.0) rspec-benchmark (~> 0.4.0) - rspec-rails (~> 3.5, >= 3.5.2) + rspec-rails (~> 3.8, >= 3.8.2) rubocop (~> 0.68.1) rubocop-performance (~> 1.2) sentry-raven (~> 2.9) diff --git a/spec/concerns/helpable_spec.rb b/spec/concerns/helpable_spec.rb index b716c1091..f01dcc545 100644 --- a/spec/concerns/helpable_spec.rb +++ b/spec/concerns/helpable_spec.rb @@ -74,7 +74,7 @@ response = subject.get_url expect(response.body.dig("data", "responseCode")).to eq(1) - expect(response.body.dig("data", "values")).to eq([{"index"=>1, "type"=>"URL", "data"=>{"format"=>"string", "value"=>"https://blog.datacite.org/"}, "ttl"=>86400, "timestamp"=>"2018-09-26T08:52:01Z"}]) + expect(response.body.dig("data", "values")).to eq([{"index"=>1, "type"=>"URL", "data"=>{"format"=>"string", "value"=>"https://blog.datacite.org/"}, "ttl"=>86400, "timestamp"=>"2019-05-10T12:45:27Z"}]) end # it 'should register on save' do diff --git a/spec/fixtures/vcr_cassettes/Doi/register_doi/should_register.yml b/spec/fixtures/vcr_cassettes/Doi/register_doi/should_register.yml index 7cc473ae8..f25f0078b 100644 --- a/spec/fixtures/vcr_cassettes/Doi/register_doi/should_register.yml +++ b/spec/fixtures/vcr_cassettes/Doi/register_doi/should_register.yml @@ -9,10 +9,10 @@ http_interactions: headers: User-Agent: - Mozilla/5.0 (compatible; Maremma/4.1.1; +https://github.com/datacite/maremma) - Content-Type: - - application/json;charset=UTF-8 Accept: - text/html,application/json,application/xml;q=0.9, text/plain;q=0.8,image/png,*/*;q=0.5 + Content-Type: + - application/json;charset=UTF-8 Authorization: - Basic response: @@ -21,7 +21,7 @@ http_interactions: message: OK headers: Date: - - Wed, 26 Sep 2018 08:52:01 GMT + - Fri, 10 May 2019 12:45:27 GMT Content-Type: - application/json;charset=UTF-8 Connection: @@ -32,7 +32,7 @@ http_interactions: encoding: ASCII-8BIT string: '{"responseCode":1,"handle":"10.5438/MCNV-GA6N"}' http_version: - recorded_at: Wed, 26 Sep 2018 08:52:01 GMT + recorded_at: Fri, 10 May 2019 12:45:27 GMT - request: method: get uri: https://handle.test.datacite.org/api/handles/10.5438/MCNV-GA6N?index=1 @@ -50,7 +50,7 @@ http_interactions: message: OK headers: Date: - - Wed, 26 Sep 2018 08:52:01 GMT + - Fri, 10 May 2019 12:45:27 GMT Content-Type: - application/json;charset=UTF-8 Connection: @@ -59,7 +59,7 @@ http_interactions: - Accept-Encoding body: encoding: ASCII-8BIT - string: '{"responseCode":1,"handle":"10.5438/MCNV-GA6N","values":[{"index":1,"type":"URL","data":{"format":"string","value":"https://blog.datacite.org/"},"ttl":86400,"timestamp":"2018-09-26T08:52:01Z"}]}' + string: '{"responseCode":1,"handle":"10.5438/MCNV-GA6N","values":[{"index":1,"type":"URL","data":{"format":"string","value":"https://blog.datacite.org/"},"ttl":86400,"timestamp":"2019-05-10T12:45:27Z"}]}' http_version: - recorded_at: Wed, 26 Sep 2018 08:52:01 GMT + recorded_at: Fri, 10 May 2019 12:45:27 GMT recorded_with: VCR 3.0.3