9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
|
# File 'lib/six-updater-web/vendor/plugins/active_scaffold/test/extensions/active_record_test.rb', line 9
def test_to_label
assert_match /^#<[a-z]+:0x[0-9a-f]+>$/i, @record.to_label
class << @record
def to_s
'to_s'
end
end
assert_equal 'to_s', @record.to_label
class << @record
def title
'title'
end
end
assert_equal 'title', @record.to_label
class << @record
def label
'label'
end
end
assert_equal 'label', @record.to_label
class << @record
def name
'name'
end
end
assert_equal 'name', @record.to_label
end
|