aboutsummaryrefslogtreecommitdiffstats
path: root/activemodel
diff options
context:
space:
mode:
authoryuuji.yaginuma <yuuji.yaginuma@gmail.com>2019-01-26 12:38:34 +0900
committeryuuji.yaginuma <yuuji.yaginuma@gmail.com>2019-01-26 12:38:34 +0900
commit6a1b7985602c5bfab4c8875ca9bf0d598e063a65 (patch)
tree31b40ba9f15611c25c03e09e18a20fb4571fca3c /activemodel
parentd05bfa6e37c43211a8416ae49e5d255097eb0bc6 (diff)
downloadrails-6a1b7985602c5bfab4c8875ca9bf0d598e063a65.tar.gz
rails-6a1b7985602c5bfab4c8875ca9bf0d598e063a65.tar.bz2
rails-6a1b7985602c5bfab4c8875ca9bf0d598e063a65.zip
Add missing require for `Float#to_d`
In master, tests pass because `bigdecimal/util` requires in `active_support/xml_mini`. But test fails in 5-2-stable because that require does not exist. Ref: https://travis-ci.org/rails/rails/jobs/484627996#L1969
Diffstat (limited to 'activemodel')
-rw-r--r--activemodel/lib/active_model/validations/numericality.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/activemodel/lib/active_model/validations/numericality.rb b/activemodel/lib/active_model/validations/numericality.rb
index 9cb8b543b0..51e224d5cd 100644
--- a/activemodel/lib/active_model/validations/numericality.rb
+++ b/activemodel/lib/active_model/validations/numericality.rb
@@ -1,5 +1,7 @@
# frozen_string_literal: true
+require "bigdecimal/util"
+
module ActiveModel
module Validations
class NumericalityValidator < EachValidator # :nodoc: