osheet 0.7.0 → 0.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/.gitignore +5 -3
- data/Gemfile +2 -0
- data/Gemfile.lock +13 -37
- data/Rakefile +3 -3
- data/lib/osheet/format/numeric.rb +0 -2
- data/lib/osheet/instance.rb +1 -3
- data/lib/osheet/version.rb +2 -2
- data/osheet.gemspec +3 -9
- data/test/cell_test.rb +96 -104
- data/test/column_test.rb +90 -97
- data/test/format/accounting_test.rb +115 -128
- data/test/format/currency_test.rb +115 -128
- data/test/format/custom_test.rb +13 -13
- data/test/format/datetime_test.rb +13 -13
- data/test/format/fraction_test.rb +63 -63
- data/test/format/general_test.rb +11 -11
- data/test/format/number_test.rb +67 -69
- data/test/format/percentage_test.rb +89 -91
- data/test/format/scientific_test.rb +89 -91
- data/test/format/special_test.rb +35 -35
- data/test/format/text_test.rb +9 -9
- data/test/format_test.rb +24 -24
- data/test/helper.rb +42 -47
- data/test/irb.rb +9 -0
- data/test/mixin_test.rb +55 -59
- data/test/osheet_test.rb +7 -10
- data/test/partial_set_test.rb +41 -61
- data/test/partial_test.rb +44 -46
- data/test/row_test.rb +92 -99
- data/test/style_set_test.rb +34 -37
- data/test/style_test.rb +72 -97
- data/test/template_set_test.rb +52 -73
- data/test/template_test.rb +31 -49
- data/test/workbook_test.rb +186 -199
- data/test/worksheet_test.rb +99 -103
- data/test/xmlss_writer/base_test.rb +72 -73
- data/test/xmlss_writer/elements_test.rb +141 -140
- data/test/xmlss_writer/styles_test.rb +197 -208
- metadata +27 -247
- data/.bundle/config +0 -2
- data/test/app_helper.rb +0 -66
- data/test/env.rb +0 -10
- data/test/rails/three/.gitignore +0 -4
- data/test/rails/three/Gemfile +0 -5
- data/test/rails/three/Gemfile.lock +0 -88
- data/test/rails/three/app/controllers/application_controller.rb +0 -3
- data/test/rails/three/app/controllers/things_controller.rb +0 -10
- data/test/rails/three/app/helpers/application_helper.rb +0 -2
- data/test/rails/three/app/views/layouts/application.html.erb +0 -14
- data/test/rails/three/app/views/things/index.xls.osheet +0 -13
- data/test/rails/three/config/application.rb +0 -42
- data/test/rails/three/config/boot.rb +0 -13
- data/test/rails/three/config/database.yml +0 -22
- data/test/rails/three/config/environment.rb +0 -5
- data/test/rails/three/config/environments/development.rb +0 -26
- data/test/rails/three/config/environments/production.rb +0 -49
- data/test/rails/three/config/environments/test.rb +0 -35
- data/test/rails/three/config/initializers/app.rb +0 -0
- data/test/rails/three/config/initializers/backtrace_silencers.rb +0 -7
- data/test/rails/three/config/initializers/inflections.rb +0 -10
- data/test/rails/three/config/initializers/mime_types.rb +0 -5
- data/test/rails/three/config/initializers/secret_token.rb +0 -7
- data/test/rails/three/config/initializers/session_store.rb +0 -8
- data/test/rails/three/config/locales/en.yml +0 -5
- data/test/rails/three/config/routes.rb +0 -3
- data/test/rails/three/config.ru +0 -4
- data/test/rails/three/db/seeds.rb +0 -7
- data/test/rails/three/doc/README_FOR_APP +0 -2
- data/test/rails/three/lib/tasks/.gitkeep +0 -0
- data/test/rails/three/script/rails +0 -6
- data/test/rails/two/.bundle/config +0 -2
- data/test/rails/two/Booting +0 -0
- data/test/rails/two/Gemfile +0 -5
- data/test/rails/two/Gemfile.lock +0 -45
- data/test/rails/two/Rails +0 -0
- data/test/rails/two/app/controllers/application_controller.rb +0 -20
- data/test/rails/two/app/controllers/things_controller.rb +0 -10
- data/test/rails/two/app/helpers/application_helper.rb +0 -3
- data/test/rails/two/app/views/things/index.xls.osheet +0 -15
- data/test/rails/two/config/boot.rb +0 -128
- data/test/rails/two/config/database.yml +0 -22
- data/test/rails/two/config/environment.rb +0 -41
- data/test/rails/two/config/environments/development.rb +0 -17
- data/test/rails/two/config/environments/production.rb +0 -28
- data/test/rails/two/config/environments/test.rb +0 -28
- data/test/rails/two/config/initializers/app.rb +0 -2
- data/test/rails/two/config/initializers/backtrace_silencers.rb +0 -7
- data/test/rails/two/config/initializers/cookie_verification_secret.rb +0 -7
- data/test/rails/two/config/initializers/inflections.rb +0 -10
- data/test/rails/two/config/initializers/mime_types.rb +0 -5
- data/test/rails/two/config/initializers/new_rails_defaults.rb +0 -21
- data/test/rails/two/config/initializers/session_store.rb +0 -15
- data/test/rails/two/config/locales/en.yml +0 -5
- data/test/rails/two/config/routes.rb +0 -3
- data/test/rails/two/db/development.sqlite3 +0 -0
- data/test/rails/two/db/seeds.rb +0 -7
- data/test/rails/two/script/about +0 -4
- data/test/rails/two/script/console +0 -3
- data/test/rails/two/script/dbconsole +0 -3
- data/test/rails/two/script/destroy +0 -3
- data/test/rails/two/script/generate +0 -3
- data/test/rails/two/script/performance/benchmarker +0 -3
- data/test/rails/two/script/performance/profiler +0 -3
- data/test/rails/two/script/plugin +0 -3
- data/test/rails/two/script/runner +0 -3
- data/test/rails/two/script/server +0 -3
- data/test/rails/two/tmp/pids/server.pid +0 -1
- data/test/rails_test.rb +0 -38
- data/test/sinatra/app.rb +0 -16
- data/test/sinatra/views/index.osheet +0 -13
- data/test/sinatra_test.rb +0 -19
data/test/style_test.rb
CHANGED
|
@@ -1,129 +1,104 @@
|
|
|
1
|
-
require "
|
|
1
|
+
require "assert"
|
|
2
2
|
require "osheet/style"
|
|
3
3
|
|
|
4
4
|
module Osheet
|
|
5
5
|
|
|
6
|
-
class StyleTest <
|
|
7
|
-
|
|
8
|
-
|
|
6
|
+
class StyleTest < Assert::Context
|
|
7
|
+
desc "Osheet::Style"
|
|
8
|
+
before { @st = Style.new('.test') }
|
|
9
|
+
subject { @st }
|
|
9
10
|
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
11
|
+
should have_reader :selectors
|
|
12
|
+
should have_instance_methods :align, :font, :bg
|
|
13
|
+
should have_instance_methods :border, :border_left, :border_top, :border_right, :border_bottom
|
|
14
|
+
should have_instance_method :match?
|
|
14
15
|
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
end
|
|
16
|
+
should "set it's defaults" do
|
|
17
|
+
assert_equal 1, subject.selectors.size
|
|
18
|
+
assert_equal '.test', subject.selectors.first
|
|
19
|
+
[ :align, :font, :bg,
|
|
20
|
+
:border_left, :border_top, :border_right, :border_bottom
|
|
21
|
+
].each do |a|
|
|
22
|
+
assert_equal [], subject.send(:get_ivar, a)
|
|
23
23
|
end
|
|
24
|
+
end
|
|
24
25
|
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
end
|
|
26
|
+
should "know it's attribute(s)" do
|
|
27
|
+
[ :align, :font, :bg,
|
|
28
|
+
:border_left, :border_top, :border_right, :border_bottom
|
|
29
|
+
].each do |a|
|
|
30
|
+
assert subject.attributes.has_key?(a)
|
|
31
31
|
end
|
|
32
|
-
|
|
33
32
|
end
|
|
34
|
-
end
|
|
35
|
-
|
|
36
|
-
class StyleSelectorTest < Test::Unit::TestCase
|
|
37
|
-
context "A Style" do
|
|
38
|
-
subject { Style.new('.test') }
|
|
39
33
|
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
end
|
|
34
|
+
should "complain about bad selectors" do
|
|
35
|
+
['poo', '#poo', 'poo poo', 'poo > poo', :poo, 123].each do |s|
|
|
36
|
+
assert_raises ArgumentError do
|
|
37
|
+
Style.new(s)
|
|
45
38
|
end
|
|
46
39
|
end
|
|
40
|
+
end
|
|
47
41
|
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
end
|
|
42
|
+
should "not complain about good selectors" do
|
|
43
|
+
['.poo', '.poo.poo', '.poo-poo', '.poo_poo'].each do |s|
|
|
44
|
+
assert_nothing_raised do
|
|
45
|
+
Style.new(s)
|
|
53
46
|
end
|
|
54
47
|
end
|
|
55
|
-
|
|
56
48
|
end
|
|
57
|
-
end
|
|
58
49
|
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
should "collect styles for #{a}" do
|
|
67
|
-
args = [1, "#FF0000", "Verdana", :love, 1.2]
|
|
68
|
-
subject.send(a, *args)
|
|
69
|
-
assert_equal args, subject.send(:get_ivar, a)
|
|
70
|
-
end
|
|
50
|
+
[ :align, :font, :bg,
|
|
51
|
+
:border_left, :border_top, :border_right, :border_bottom
|
|
52
|
+
].each do |a|
|
|
53
|
+
should "collect styles for #{a}" do
|
|
54
|
+
args = [1, "#FF0000", "Verdana", :love, 1.2]
|
|
55
|
+
subject.send(a, *args)
|
|
56
|
+
assert_equal args, subject.send(:get_ivar, a)
|
|
71
57
|
end
|
|
58
|
+
end
|
|
72
59
|
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
end
|
|
60
|
+
should "set all border positions to the same styles using 'border' macro collector" do
|
|
61
|
+
args = [:thick, '#FF00FF', :dot]
|
|
62
|
+
subject.border *args
|
|
63
|
+
[ :border_left, :border_top, :border_right, :border_bottom].each do |a|
|
|
64
|
+
assert_equal args, subject.send(:get_ivar, a)
|
|
79
65
|
end
|
|
80
|
-
|
|
81
66
|
end
|
|
82
|
-
end
|
|
83
|
-
|
|
84
|
-
class StyleMatcherTest < Test::Unit::TestCase
|
|
85
|
-
context "A Style" do
|
|
86
|
-
subject { Style.new }
|
|
87
67
|
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
end
|
|
68
|
+
should "match on style class strings" do
|
|
69
|
+
a = Style.new('.awesome') {}
|
|
70
|
+
at = Style.new('.awesome.thing') {}
|
|
71
|
+
b = Style.new('.boring') {}
|
|
72
|
+
bt = Style.new('.boring.thing') {}
|
|
73
|
+
a_b = Style.new('.awesome', '.boring') {}
|
|
74
|
+
t = Style.new('.thing') {}
|
|
75
|
+
s = Style.new('.stupid') {}
|
|
76
|
+
|
|
77
|
+
{ 'awesome' => [a, a_b],
|
|
78
|
+
'boring' => [b, a_b],
|
|
79
|
+
'thing' => [t],
|
|
80
|
+
'awesome thing' => [a, at, a_b, t],
|
|
81
|
+
'thing awesome' => [a, at, a_b, t],
|
|
82
|
+
'other' => []
|
|
83
|
+
}.each do |style_class, styles|
|
|
84
|
+
styles.each do |style|
|
|
85
|
+
assert_equal true, style.match?(style_class)
|
|
107
86
|
end
|
|
108
|
-
assert_equal false, a.match?('stupid')
|
|
109
87
|
end
|
|
110
|
-
|
|
88
|
+
assert_equal false, a.match?('stupid')
|
|
111
89
|
end
|
|
112
|
-
end
|
|
113
90
|
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
@test = 20
|
|
118
|
-
@style = Style.new('.test') { font @test }
|
|
91
|
+
should "access instance vars from that block's binding" do
|
|
92
|
+
@test = 20
|
|
93
|
+
@style = Style.new('.test') { font @test }
|
|
119
94
|
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
end
|
|
95
|
+
assert !@style.send(:instance_variable_get, "@test").nil?
|
|
96
|
+
assert_equal @test, @style.send(:instance_variable_get, "@test")
|
|
97
|
+
assert_equal @test.object_id, @style.send(:instance_variable_get, "@test").object_id
|
|
98
|
+
assert_equal @test, @style.attributes[:font].first
|
|
99
|
+
assert_equal @test.object_id, @style.attributes[:font].first.object_id
|
|
126
100
|
end
|
|
101
|
+
|
|
127
102
|
end
|
|
128
103
|
|
|
129
104
|
end
|
data/test/template_set_test.rb
CHANGED
|
@@ -1,95 +1,74 @@
|
|
|
1
|
-
require "
|
|
1
|
+
require "assert"
|
|
2
2
|
require "osheet/template_set"
|
|
3
3
|
|
|
4
4
|
module Osheet
|
|
5
|
-
class TemplateSetTest <
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
should "be a PartialSet" do
|
|
11
|
-
assert_kind_of PartialSet, subject
|
|
12
|
-
end
|
|
13
|
-
|
|
14
|
-
should "verify set objs are templates" do
|
|
15
|
-
assert_raises ArgumentError do
|
|
16
|
-
subject.send(:verify, {})
|
|
17
|
-
end
|
|
18
|
-
assert_nothing_raised do
|
|
19
|
-
subject.send(:verify, Template.new(:row, :poo) {})
|
|
20
|
-
end
|
|
21
|
-
end
|
|
5
|
+
class TemplateSetTest < Assert::Context
|
|
6
|
+
desc "Osheet::TemplateSet"
|
|
7
|
+
before { @set = TemplateSet.new }
|
|
8
|
+
subject { @set }
|
|
22
9
|
|
|
10
|
+
should "be a PartialSet" do
|
|
11
|
+
assert_kind_of PartialSet, subject
|
|
23
12
|
end
|
|
24
|
-
end
|
|
25
|
-
|
|
26
|
-
class TemplateSetKeyTest < Test::Unit::TestCase
|
|
27
|
-
context "A template set" do
|
|
28
|
-
subject { TemplateSet.new }
|
|
29
13
|
|
|
30
|
-
|
|
31
|
-
|
|
14
|
+
should "verify set objs are templates" do
|
|
15
|
+
assert_raises ArgumentError do
|
|
16
|
+
subject.send(:verify, {})
|
|
32
17
|
end
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
assert_equal ['row', 'poo'], subject.send(:template_key, Template.new(:row, :poo) {})
|
|
18
|
+
assert_nothing_raised do
|
|
19
|
+
subject.send(:verify, Template.new(:row, :poo) {})
|
|
36
20
|
end
|
|
21
|
+
end
|
|
37
22
|
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
assert_equal({
|
|
42
|
-
key.first => { key.last => nil }
|
|
43
|
-
}, subject)
|
|
44
|
-
end
|
|
23
|
+
should "key templates using an array of their element and name" do
|
|
24
|
+
assert_equal ['row','poo'], subject.send(:key, :row, :poo)
|
|
25
|
+
end
|
|
45
26
|
|
|
27
|
+
should "key on templates objs" do
|
|
28
|
+
assert_equal ['row', 'poo'], subject.send(:template_key, Template.new(:row, :poo) {})
|
|
46
29
|
end
|
|
47
|
-
end
|
|
48
30
|
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
subject << Template.new(:column, :awesome) {}
|
|
57
|
-
subject << Template.new(:column, :not_awesome) {}
|
|
58
|
-
end
|
|
31
|
+
should "init the key in the set when verifying" do
|
|
32
|
+
key = subject.send(:verify, Template.new(:row, :poo) {})
|
|
33
|
+
assert_equal ['row', 'poo'], key
|
|
34
|
+
assert_equal({
|
|
35
|
+
key.first => { key.last => nil }
|
|
36
|
+
}, subject)
|
|
37
|
+
end
|
|
59
38
|
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
assert_kind_of Template, subject["row"]["not_poo"]
|
|
67
|
-
assert subject["column"]
|
|
68
|
-
assert_equal 2, subject["column"].keys.size
|
|
69
|
-
assert subject["column"]["awesome"]
|
|
70
|
-
assert_kind_of Template, subject["column"]["awesome"]
|
|
71
|
-
assert subject["column"]["not_awesome"]
|
|
72
|
-
assert_kind_of Template, subject["column"]["not_awesome"]
|
|
39
|
+
should "push templates onto the set" do
|
|
40
|
+
assert_nothing_raised do
|
|
41
|
+
subject << Template.new(:row, :poo) {}
|
|
42
|
+
subject << Template.new(:row, :not_poo) {}
|
|
43
|
+
subject << Template.new(:column, :awesome) {}
|
|
44
|
+
subject << Template.new(:column, :not_awesome) {}
|
|
73
45
|
end
|
|
74
46
|
|
|
47
|
+
assert_equal 2, subject.keys.size
|
|
48
|
+
assert subject["row"]
|
|
49
|
+
assert_equal 2, subject["row"].keys.size
|
|
50
|
+
assert subject["row"]["poo"]
|
|
51
|
+
assert_kind_of Template, subject["row"]["poo"]
|
|
52
|
+
assert subject["row"]["not_poo"]
|
|
53
|
+
assert_kind_of Template, subject["row"]["not_poo"]
|
|
54
|
+
assert subject["column"]
|
|
55
|
+
assert_equal 2, subject["column"].keys.size
|
|
56
|
+
assert subject["column"]["awesome"]
|
|
57
|
+
assert_kind_of Template, subject["column"]["awesome"]
|
|
58
|
+
assert subject["column"]["not_awesome"]
|
|
59
|
+
assert_kind_of Template, subject["column"]["not_awesome"]
|
|
75
60
|
end
|
|
76
|
-
end
|
|
77
61
|
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
subject
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
t = Template.new(:row, :poo) {}
|
|
84
|
-
subject << t
|
|
85
|
-
assert_equal t, subject.get(:row, :poo)
|
|
86
|
-
assert_equal t, subject.get('row', 'poo')
|
|
87
|
-
|
|
88
|
-
assert_equal nil, subject.get(:row, :ugh)
|
|
89
|
-
assert_equal nil, subject.get(:col, :ugh)
|
|
90
|
-
end
|
|
62
|
+
should "lookup a template by element, name" do
|
|
63
|
+
t = Template.new(:row, :poo) {}
|
|
64
|
+
subject << t
|
|
65
|
+
assert_equal t, subject.get(:row, :poo)
|
|
66
|
+
assert_equal t, subject.get('row', 'poo')
|
|
91
67
|
|
|
68
|
+
assert_equal nil, subject.get(:row, :ugh)
|
|
69
|
+
assert_equal nil, subject.get(:col, :ugh)
|
|
92
70
|
end
|
|
71
|
+
|
|
93
72
|
end
|
|
94
73
|
|
|
95
74
|
end
|
data/test/template_test.rb
CHANGED
|
@@ -1,66 +1,48 @@
|
|
|
1
|
-
require "
|
|
1
|
+
require "assert"
|
|
2
2
|
require "osheet/template"
|
|
3
3
|
|
|
4
4
|
module Osheet
|
|
5
5
|
|
|
6
|
-
class TemplateTest <
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
6
|
+
class TemplateTest < Assert::Context
|
|
7
|
+
desc "Osheet::Template"
|
|
8
|
+
before do
|
|
9
|
+
@tmpl = Template.new('column', :thing) {}
|
|
10
|
+
end
|
|
11
|
+
subject { @tmpl }
|
|
11
12
|
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
13
|
+
should "define what elements it is valid for" do
|
|
14
|
+
assert_equal ['worksheet', 'column', 'row', 'cell'], Template::ELEMENTS
|
|
15
|
+
end
|
|
15
16
|
|
|
16
|
-
|
|
17
|
+
should have_accessor :element
|
|
17
18
|
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
should "convert the element ars to string and store off" do
|
|
23
|
-
assert_equal 'column', subject.element
|
|
24
|
-
end
|
|
19
|
+
should "be a Partial" do
|
|
20
|
+
assert_kind_of Partial, subject
|
|
21
|
+
end
|
|
25
22
|
|
|
23
|
+
should "convert the element ars to string and store off" do
|
|
24
|
+
assert_equal 'column', subject.element
|
|
26
25
|
end
|
|
26
|
+
|
|
27
27
|
end
|
|
28
28
|
|
|
29
|
-
class TemplateElementTest <
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
29
|
+
class TemplateElementTest < TemplateTest
|
|
30
|
+
desc "a template"
|
|
31
|
+
|
|
32
|
+
should "verify the element argument" do
|
|
33
|
+
assert_raises ArgumentError do
|
|
34
|
+
Template.new({}, :poo) {}
|
|
35
|
+
end
|
|
36
|
+
assert_raises ArgumentError do
|
|
37
|
+
Template.new('workbook', :poo) {}
|
|
38
|
+
end
|
|
39
|
+
Template::ELEMENTS.each do |elem|
|
|
40
|
+
assert_nothing_raised do
|
|
41
|
+
Template.new(elem, :poo) {}
|
|
42
42
|
end
|
|
43
43
|
end
|
|
44
|
-
|
|
45
44
|
end
|
|
46
|
-
end
|
|
47
45
|
|
|
48
|
-
|
|
49
|
-
# context "a template defined w/ a block" do
|
|
50
|
-
# should "access instance vars from that block's binding" do
|
|
51
|
-
# @test = 'test thing'
|
|
52
|
-
# @workbook = Workbook.new {
|
|
53
|
-
# template('worksheet', :thing) { name @test }
|
|
54
|
-
# worksheet(:thing)
|
|
55
|
-
# }
|
|
56
|
-
#
|
|
57
|
-
# assert !@workbook.worksheets.first.send(:instance_variable_get, "@test").nil?
|
|
58
|
-
# assert_equal @test, @workbook.worksheets.first.send(:instance_variable_get, "@test")
|
|
59
|
-
# assert_equal @test.object_id, @workbook.worksheets.first.send(:instance_variable_get, "@test").object_id
|
|
60
|
-
# assert_equal @test, @workbook.worksheets.first.attributes[:name]
|
|
61
|
-
# assert_equal @test.object_id, @workbook.worksheets.first.attributes[:name].object_id
|
|
62
|
-
# end
|
|
63
|
-
# end
|
|
64
|
-
# end
|
|
46
|
+
end
|
|
65
47
|
|
|
66
48
|
end
|