mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
Mark Class as not being duplicable. [#829 state:resolved]
Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
This commit is contained in:
parent
bbedb6a624
commit
654c41255d
2 changed files with 7 additions and 1 deletions
|
@ -35,3 +35,9 @@ class Numeric #:nodoc:
|
|||
false
|
||||
end
|
||||
end
|
||||
|
||||
class Class #:nodoc:
|
||||
def duplicable?
|
||||
false
|
||||
end
|
||||
end
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
require 'abstract_unit'
|
||||
|
||||
class DuplicableTest < Test::Unit::TestCase
|
||||
NO = [nil, false, true, :symbol, 1, 2.3, BigDecimal.new('4.56')]
|
||||
NO = [nil, false, true, :symbol, 1, 2.3, BigDecimal.new('4.56'), Class.new]
|
||||
YES = ['1', Object.new, /foo/, [], {}, Time.now]
|
||||
|
||||
def test_duplicable
|
||||
|
|
Loading…
Reference in a new issue