upgrade to rails 6. Failing tests

pull/1/head
rebuilt 4 years ago
parent 68357e65ec
commit 3430069801

@ -8,7 +8,7 @@ end
# Bundle edge Rails instead: gem 'rails', github: 'rails/rails' # Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
gem 'rails', '~> 5.2.6' gem 'rails', '~> 6.0.4.1'
gem 'pg' gem 'pg'

@ -10,52 +10,65 @@ GIT
GEM GEM
remote: https://rubygems.org/ remote: https://rubygems.org/
specs: specs:
actioncable (5.2.6) actioncable (6.0.4.1)
actionpack (= 5.2.6) actionpack (= 6.0.4.1)
nio4r (~> 2.0) nio4r (~> 2.0)
websocket-driver (>= 0.6.1) websocket-driver (>= 0.6.1)
actionmailer (5.2.6) actionmailbox (6.0.4.1)
actionpack (= 5.2.6) actionpack (= 6.0.4.1)
actionview (= 5.2.6) activejob (= 6.0.4.1)
activejob (= 5.2.6) activerecord (= 6.0.4.1)
activestorage (= 6.0.4.1)
activesupport (= 6.0.4.1)
mail (>= 2.7.1)
actionmailer (6.0.4.1)
actionpack (= 6.0.4.1)
actionview (= 6.0.4.1)
activejob (= 6.0.4.1)
mail (~> 2.5, >= 2.5.4) mail (~> 2.5, >= 2.5.4)
rails-dom-testing (~> 2.0) rails-dom-testing (~> 2.0)
actionpack (5.2.6) actionpack (6.0.4.1)
actionview (= 5.2.6) actionview (= 6.0.4.1)
activesupport (= 5.2.6) activesupport (= 6.0.4.1)
rack (~> 2.0, >= 2.0.8) rack (~> 2.0, >= 2.0.8)
rack-test (>= 0.6.3) rack-test (>= 0.6.3)
rails-dom-testing (~> 2.0) rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.0, >= 1.0.2) rails-html-sanitizer (~> 1.0, >= 1.2.0)
actionview (5.2.6) actiontext (6.0.4.1)
activesupport (= 5.2.6) actionpack (= 6.0.4.1)
activerecord (= 6.0.4.1)
activestorage (= 6.0.4.1)
activesupport (= 6.0.4.1)
nokogiri (>= 1.8.5)
actionview (6.0.4.1)
activesupport (= 6.0.4.1)
builder (~> 3.1) builder (~> 3.1)
erubi (~> 1.4) erubi (~> 1.4)
rails-dom-testing (~> 2.0) rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.0, >= 1.0.3) rails-html-sanitizer (~> 1.1, >= 1.2.0)
activejob (5.2.6) activejob (6.0.4.1)
activesupport (= 5.2.6) activesupport (= 6.0.4.1)
globalid (>= 0.3.6) globalid (>= 0.3.6)
activemodel (5.2.6) activemodel (6.0.4.1)
activesupport (= 5.2.6) activesupport (= 6.0.4.1)
activerecord (5.2.6) activerecord (6.0.4.1)
activemodel (= 5.2.6) activemodel (= 6.0.4.1)
activesupport (= 5.2.6) activesupport (= 6.0.4.1)
arel (>= 9.0)
activerecord-import (1.2.0) activerecord-import (1.2.0)
activerecord (>= 3.2) activerecord (>= 3.2)
activestorage (5.2.6) activestorage (6.0.4.1)
actionpack (= 5.2.6) actionpack (= 6.0.4.1)
activerecord (= 5.2.6) activejob (= 6.0.4.1)
activerecord (= 6.0.4.1)
marcel (~> 1.0.0) marcel (~> 1.0.0)
activesupport (5.2.6) activesupport (6.0.4.1)
concurrent-ruby (~> 1.0, >= 1.0.2) concurrent-ruby (~> 1.0, >= 1.0.2)
i18n (>= 0.7, < 2) i18n (>= 0.7, < 2)
minitest (~> 5.1) minitest (~> 5.1)
tzinfo (~> 1.1) tzinfo (~> 1.1)
zeitwerk (~> 2.2, >= 2.2.2)
addressable (2.8.0) addressable (2.8.0)
public_suffix (>= 2.0.2, < 5.0) public_suffix (>= 2.0.2, < 5.0)
arel (9.0.0)
autoprefixer-rails (10.3.3.0) autoprefixer-rails (10.3.3.0)
execjs (~> 2) execjs (~> 2)
bcrypt (3.1.16) bcrypt (3.1.16)
@ -149,18 +162,20 @@ GEM
rack rack
rack-test (1.1.0) rack-test (1.1.0)
rack (>= 1.0, < 3) rack (>= 1.0, < 3)
rails (5.2.6) rails (6.0.4.1)
actioncable (= 5.2.6) actioncable (= 6.0.4.1)
actionmailer (= 5.2.6) actionmailbox (= 6.0.4.1)
actionpack (= 5.2.6) actionmailer (= 6.0.4.1)
actionview (= 5.2.6) actionpack (= 6.0.4.1)
activejob (= 5.2.6) actiontext (= 6.0.4.1)
activemodel (= 5.2.6) actionview (= 6.0.4.1)
activerecord (= 5.2.6) activejob (= 6.0.4.1)
activestorage (= 5.2.6) activemodel (= 6.0.4.1)
activesupport (= 5.2.6) activerecord (= 6.0.4.1)
activestorage (= 6.0.4.1)
activesupport (= 6.0.4.1)
bundler (>= 1.3.0) bundler (>= 1.3.0)
railties (= 5.2.6) railties (= 6.0.4.1)
sprockets-rails (>= 2.0.0) sprockets-rails (>= 2.0.0)
rails-controller-testing (1.0.5) rails-controller-testing (1.0.5)
actionpack (>= 5.0.1.rc1) actionpack (>= 5.0.1.rc1)
@ -171,12 +186,12 @@ GEM
nokogiri (>= 1.6) nokogiri (>= 1.6)
rails-html-sanitizer (1.4.2) rails-html-sanitizer (1.4.2)
loofah (~> 2.3) loofah (~> 2.3)
railties (5.2.6) railties (6.0.4.1)
actionpack (= 5.2.6) actionpack (= 6.0.4.1)
activesupport (= 5.2.6) activesupport (= 6.0.4.1)
method_source method_source
rake (>= 0.8.7) rake (>= 0.8.7)
thor (>= 0.19.0, < 2.0) thor (>= 0.20.3, < 2.0)
rake (13.0.6) rake (13.0.6)
rb-fsevent (0.11.0) rb-fsevent (0.11.0)
rb-inotify (0.10.1) rb-inotify (0.10.1)
@ -242,16 +257,17 @@ GEM
execjs (>= 0.3.0, < 3) execjs (>= 0.3.0, < 3)
warden (1.2.9) warden (1.2.9)
rack (>= 2.0.9) rack (>= 2.0.9)
web-console (3.7.0) web-console (4.1.0)
actionview (>= 5.0) actionview (>= 6.0.0)
activemodel (>= 5.0) activemodel (>= 6.0.0)
bindex (>= 0.4.0) bindex (>= 0.4.0)
railties (>= 5.0) railties (>= 6.0.0)
websocket-driver (0.7.5) websocket-driver (0.7.5)
websocket-extensions (>= 0.1.0) websocket-extensions (>= 0.1.0)
websocket-extensions (0.1.5) websocket-extensions (0.1.5)
xpath (3.2.0) xpath (3.2.0)
nokogiri (~> 1.8) nokogiri (~> 1.8)
zeitwerk (2.4.2)
PLATFORMS PLATFORMS
x86_64-linux x86_64-linux
@ -276,7 +292,7 @@ DEPENDENCIES
omniauth omniauth
pg pg
puma (~> 3.0) puma (~> 3.0)
rails (~> 5.2.6) rails (~> 6.0.4.1)
rails-controller-testing rails-controller-testing
rspec-rails (~> 4.1.2) rspec-rails (~> 4.1.2)
sassc-rails sassc-rails

@ -27,7 +27,7 @@ class GaugePresenter
end end
def percentage_for(number) def percentage_for(number)
number ||= 0 return 0 if number.nil?
scale_minimum = @scale.warning_zone.low_benchmark scale_minimum = @scale.warning_zone.low_benchmark
scale_maximum = @scale.ideal_zone.high_benchmark scale_maximum = @scale.ideal_zone.high_benchmark

@ -11,6 +11,7 @@ RSpec.describe "schools/show", type: :view do
it "renders attributes in <p>" do it "renders attributes in <p>" do
render render
puts rendered.class
expect(rendered).to match(/School/) expect(rendered).to match(/School/)
expect(rendered).to match(/District/) expect(rendered).to match(/District/)
end end

Loading…
Cancel
Save