From 2c29dee3bcf91190e8ea08d3ef2bbd7f80fbe6ab Mon Sep 17 00:00:00 2001 From: Martin Fenner Date: Sun, 15 Dec 2019 20:36:23 +0100 Subject: [PATCH] upgraded oj gem to version 3 --- Gemfile | 8 +++---- Gemfile.lock | 38 ++++++++++++++++-------------- spec/concerns/crosscitable_spec.rb | 8 +++---- 3 files changed, 28 insertions(+), 26 deletions(-) diff --git a/Gemfile b/Gemfile index e220118e6..12dda24b4 100644 --- a/Gemfile +++ b/Gemfile @@ -9,14 +9,14 @@ gem "dotenv" gem "rake", "~> 12.0" gem "oj", ">= 2.8.3" gem "oj_mimic_json", "~> 1.0", ">= 1.0.1" -gem "jsonlint", "~> 0.2.0" +gem "jsonlint", "~> 0.3.0" gem "equivalent-xml", "~> 0.6.0" gem "nokogiri", ">= 1.10.4" gem "diffy", "~> 3.2", ">= 3.2.1" gem "commonmarker", "~> 0.17.9" gem "iso8601", "~> 0.9.0" gem "maremma", ">= 4.1" -gem "bolognese", "~> 1.0" +gem "bolognese", "~> 1.0", ">= 1.4" gem "dalli", "~> 2.7", ">= 2.7.6" gem "lograge", "~> 0.11.2" gem "logstash-event", "~> 1.2", ">= 1.2.02" @@ -43,7 +43,7 @@ gem "bergamasco", "~> 0.3.10" gem "base32-url", "~> 0.3" gem "mailgun-ruby", "~> 1.1", ">= 1.1.8" gem "premailer", "~> 1.11", ">= 1.11.1" -gem "flipper", "~> 0.16.0" +gem "flipper", "~> 0.17.0" gem "flipper-active_support_cache_store" gem "rack-cors", "~> 1.0", require: "rack/cors" gem "strip_attributes", "~> 1.8" @@ -53,7 +53,7 @@ gem "elasticsearch", "~> 7.1.0" gem "elasticsearch-model", "~> 7.0", require: "elasticsearch/model" gem "elasticsearch-rails", "~> 7.0" gem "faraday", "0.17.0" -gem "faraday_middleware-aws-sigv4", "~> 0.2.4" +gem "faraday_middleware-aws-sigv4", "~> 0.3.0" gem "rack-utf8_sanitizer", "~> 1.6" gem "turnout", "~> 2.5" gem "audited", "~> 4.8" diff --git a/Gemfile.lock b/Gemfile.lock index da8f86038..1cd0907ba 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -109,7 +109,7 @@ GEM latex-decode (~> 0.0) binding_of_caller (0.8.0) debug_inspector (>= 0.0.1) - bolognese (1.3.23) + bolognese (1.4) activesupport (>= 4.2.5, < 6) benchmark_methods (~> 0.7) bibtex-ruby (~> 4.1) @@ -119,15 +119,17 @@ GEM concurrent-ruby (~> 1.0.5) csl-styles (~> 1.0, >= 1.0.1.8) edtf (~> 3.0, >= 3.0.4) + faraday (= 0.17.0) gender_detector (~> 0.1.2) iso8601 (~> 0.9.1) json-ld-preloaded (= 3.0.2) - jsonlint (~> 0.2.0) + jsonlint (~> 0.3.0) loofah (~> 2.0, >= 2.0.3) maremma (>= 4.3, < 5) namae (~> 1.0) nokogiri (~> 1.10.4) - oj (>= 2.8.3) + oj (~> 3.10) + oj_mimic_json (~> 1.0, >= 1.0.1) postrank-uri (~> 1.0, >= 1.0.18) rdf-rdfxml (~> 2.2) rdf-turtle (~> 3.0, >= 3.0.6) @@ -225,16 +227,16 @@ GEM faraday faraday_middleware (0.13.1) faraday (>= 0.7.4, < 1.0) - faraday_middleware-aws-sigv4 (0.2.4) + faraday_middleware-aws-sigv4 (0.3.0) aws-sigv4 (~> 1.0) - faraday (>= 0.9) + faraday (>= 0.15) fast_jsonapi (1.5) activesupport (>= 4.2) ffi (1.11.3) - flipper (0.16.2) - flipper-active_support_cache_store (0.16.2) - activesupport (>= 3.2, < 6) - flipper (~> 0.16.2) + flipper (0.17.1) + flipper-active_support_cache_store (0.17.1) + activesupport (>= 4.2, < 7) + flipper (~> 0.17.1) gender_detector (0.1.2) unicode_utils (>= 1.3.0) git (1.5.0) @@ -272,9 +274,9 @@ GEM multi_json (~> 1.12) rdf (~> 3.0) jsonapi-renderer (0.2.2) - jsonlint (0.2.0) - oj (~> 2) - trollop (~> 2) + jsonlint (0.3.0) + oj (~> 3) + optimist (~> 3) jwt (2.2.1) kaminari (1.1.1) activesupport (>= 4.1.0) @@ -342,8 +344,9 @@ GEM nio4r (2.5.2) nokogiri (1.10.7) mini_portile2 (~> 2.4.0) - oj (2.18.5) + oj (3.10.0) oj_mimic_json (1.0.1) + optimist (3.0.0) pandoc-ruby (2.0.2) parallel (1.19.1) parser (2.6.5.0) @@ -511,7 +514,6 @@ GEM thor (0.20.3) thread_safe (0.3.6) tilt (2.0.10) - trollop (2.9.10) turnout (2.5.0) i18n (>= 0.7, < 2) rack (>= 1.3, < 3) @@ -551,7 +553,7 @@ DEPENDENCIES bergamasco (~> 0.3.10) better_errors binding_of_caller - bolognese (~> 1.0) + bolognese (~> 1.0, >= 1.4) bootsnap (~> 1.4, >= 1.4.4) byebug cancancan (~> 2.0) @@ -573,9 +575,9 @@ DEPENDENCIES factory_bot_rails (~> 4.8, >= 4.8.2) faker (~> 1.9) faraday (= 0.17.0) - faraday_middleware-aws-sigv4 (~> 0.2.4) + faraday_middleware-aws-sigv4 (~> 0.3.0) fast_jsonapi (~> 1.3) - flipper (~> 0.16.0) + flipper (~> 0.17.0) flipper-active_support_cache_store gender_detector (~> 0.1.2) git (~> 1.5) @@ -586,7 +588,7 @@ DEPENDENCIES graphql-errors (~> 0.4.0) hashdiff (>= 1.0.0.beta1, < 2.0.0) iso8601 (~> 0.9.0) - jsonlint (~> 0.2.0) + jsonlint (~> 0.3.0) jwt kaminari (~> 1.0, >= 1.0.1) listen (>= 3.0.5, < 3.2) diff --git a/spec/concerns/crosscitable_spec.rb b/spec/concerns/crosscitable_spec.rb index b41f18db7..83bf7d1ce 100644 --- a/spec/concerns/crosscitable_spec.rb +++ b/spec/concerns/crosscitable_spec.rb @@ -52,12 +52,12 @@ it "from_json starts with unexpected character" do string = file_fixture('datacite.xml').read - expect { subject.from_json(string) }.to raise_error(JSON::ParserError, "unexpected character at line 1, column 1 [parse.c:671]") + expect { subject.from_json(string) }.to raise_error(JSON::ParserError, /Empty input \(\) at line 1, column 1/) end it "from_json malformed" do string = file_fixture('citeproc_malformed.json').read - expect { subject.from_json(string) }.to raise_error(JSON::ParserError, "expected comma, not a string at line 4, column 9 [parse.c:381]") + expect { subject.from_json(string) }.to raise_error(JSON::ParserError, /expected comma, not a string \(id\) at line 4, column 9/) end it "from_json duplicate keys" do @@ -84,12 +84,12 @@ it "from_json starts with unexpected character" do string = 'abc' - expect { subject.well_formed_xml(string) }.to raise_error(JSON::ParserError, "unexpected character at line 1, column 1 [parse.c:671]") + expect { subject.well_formed_xml(string) }.to raise_error(JSON::ParserError, /Empty input \(\) at line 1, column 1/) end it "from_json malformed" do string = file_fixture('citeproc_malformed.json').read - expect { subject.well_formed_xml(string) }.to raise_error(JSON::ParserError, "expected comma, not a string at line 4, column 9 [parse.c:381]") + expect { subject.well_formed_xml(string) }.to raise_error(JSON::ParserError, /expected comma/) end it "from_json duplicate keys" do