roo 1.13.1 → 1.13.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: dc5611ebf2e74bc1b5e0219a3c4ee552a1345b83
4
- data.tar.gz: 4f462e45c9efc037c7f76b83a58d96254d261722
3
+ metadata.gz: 2469a06f8110bdaa52d7a0aa1b9c5c870034b3d8
4
+ data.tar.gz: 5211e3ae85961fc29376156120569220cbfbbe7b
5
5
  SHA512:
6
- metadata.gz: 573fcda9fdfbd0ff4234bba0cdcf803fdf34d49786e4ecba3af230cb92827ffa3c6f2f9a5ca7bcfe086c0835ca270499549d9c22b9224fd93925d7bd5c6bdcf3
7
- data.tar.gz: 2810f3f8f678ecf6fac952eb445dae8d8716fcb96f7c82924c29785319ba3b3cac1f55da95ab615fb22d2e7890d4884e5c509173e170d1af6a3c2b2af339c4a2
6
+ metadata.gz: bbae1e0e681f369f4ec0ee8c71a880c3b6fe24cc815cde0b337bd63e77a0103edf04b77de320a212e772a8ac1a68ad9ee5f5be3b52672806fbc18592536db83d
7
+ data.tar.gz: 91a54b399f41ee9d459b9bb3868c5cd2990963297c274f4dc5f4a78034137a8c617f9ac34db75418e8f0989683219637cb9a096536259e9cb76fe9cca780b132
data/CHANGELOG CHANGED
@@ -1,3 +1,8 @@
1
+ == 1.13.2 2013-12-23
2
+
3
+ * bugfixes
4
+ * Fix that Excelx link-cells would blow up if the value wasn't a string. Due to the way Spreadsheet::Link is implemented the link text must be treated as a string. #92
5
+
1
6
  == 1.13.1 2013-12-23
2
7
 
3
8
  * bugfixes
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.13.1
1
+ 1.13.2
@@ -376,7 +376,7 @@ class Roo::Excelx < Roo::Base
376
376
  v
377
377
  end
378
378
 
379
- @cell[sheet][key] = Spreadsheet::Link.new(@hyperlink[sheet][key], @cell[sheet][key]) if hyperlink?(y,x+i)
379
+ @cell[sheet][key] = Spreadsheet::Link.new(@hyperlink[sheet][key], @cell[sheet][key].to_s) if hyperlink?(y,x+i)
380
380
  @excelx_type[sheet] ||= {}
381
381
  @excelx_type[sheet][key] = excelx_type
382
382
  @excelx_value[sheet] ||= {}
@@ -5,7 +5,7 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = "roo"
8
- s.version = "1.13.1"
8
+ s.version = "1.13.2"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Thomas Preymesser", "Hugh McGowan", "Ben Woosley"]
@@ -125,6 +125,7 @@ Gem::Specification.new do |s|
125
125
  "test/files/numbers1.xls",
126
126
  "test/files/numbers1.xlsx",
127
127
  "test/files/numbers1.xml",
128
+ "test/files/numeric-link.xlsx",
128
129
  "test/files/only_one_sheet.ods",
129
130
  "test/files/only_one_sheet.xls",
130
131
  "test/files/only_one_sheet.xlsx",
@@ -179,7 +180,7 @@ Gem::Specification.new do |s|
179
180
  s.required_ruby_version = Gem::Requirement.new(">= 1.9.0")
180
181
  s.rubygems_version = "2.0.14"
181
182
  s.summary = "Roo can access the contents of various spreadsheet files."
182
- s.test_files = ["spec/fixtures/vcr_cassettes/google_drive.yml", "spec/fixtures/vcr_cassettes/google_drive_access_token.yml", "spec/fixtures/vcr_cassettes/google_drive_set.yml", "spec/lib/roo/base_spec.rb", "spec/lib/roo/csv_spec.rb", "spec/lib/roo/excel2003xml_spec.rb", "spec/lib/roo/excel_spec.rb", "spec/lib/roo/excelx/format_spec.rb", "spec/lib/roo/excelx_spec.rb", "spec/lib/roo/google_spec.rb", "spec/lib/roo/libreoffice_spec.rb", "spec/lib/roo/openoffice_spec.rb", "spec/lib/roo/spreadsheet_spec.rb", "spec/spec_helper.rb", "test/all_ss.rb", "test/files/1900_base.xls", "test/files/1900_base.xlsx", "test/files/1904_base.xls", "test/files/1904_base.xlsx", "test/files/Bibelbund.csv", "test/files/Bibelbund.ods", "test/files/Bibelbund.xls", "test/files/Bibelbund.xlsx", "test/files/Bibelbund.xml", "test/files/Bibelbund1.ods", "test/files/Pfand_from_windows_phone.xlsx", "test/files/bad_excel_date.xls", "test/files/bbu.ods", "test/files/bbu.xls", "test/files/bbu.xlsx", "test/files/bbu.xml", "test/files/bode-v1.ods.zip", "test/files/bode-v1.xls.zip", "test/files/boolean.csv", "test/files/boolean.ods", "test/files/boolean.xls", "test/files/boolean.xlsx", "test/files/boolean.xml", "test/files/borders.ods", "test/files/borders.xls", "test/files/borders.xlsx", "test/files/borders.xml", "test/files/bug-numbered-sheet-names.xlsx", "test/files/bug-row-column-fixnum-float.xls", "test/files/bug-row-column-fixnum-float.xml", "test/files/comments.ods", "test/files/comments.xls", "test/files/comments.xlsx", "test/files/csvtypes.csv", "test/files/datetime.ods", "test/files/datetime.xls", "test/files/datetime.xlsx", "test/files/datetime.xml", "test/files/datetime_floatconv.xls", "test/files/datetime_floatconv.xml", "test/files/dreimalvier.ods", "test/files/emptysheets.ods", "test/files/emptysheets.xls", "test/files/emptysheets.xlsx", "test/files/emptysheets.xml", "test/files/excel2003.xml", "test/files/false_encoding.xls", "test/files/false_encoding.xml", "test/files/file_item_error.xlsx", "test/files/formula.ods", "test/files/formula.xls", "test/files/formula.xlsx", "test/files/formula.xml", "test/files/formula_parse_error.xls", "test/files/formula_parse_error.xml", "test/files/formula_string_error.xlsx", "test/files/html-escape.ods", "test/files/link.xls", "test/files/link.xlsx", "test/files/matrix.ods", "test/files/matrix.xls", "test/files/named_cells.ods", "test/files/named_cells.xls", "test/files/named_cells.xlsx", "test/files/no_spreadsheet_file.txt", "test/files/numbers1.csv", "test/files/numbers1.ods", "test/files/numbers1.xls", "test/files/numbers1.xlsx", "test/files/numbers1.xml", "test/files/only_one_sheet.ods", "test/files/only_one_sheet.xls", "test/files/only_one_sheet.xlsx", "test/files/only_one_sheet.xml", "test/files/paragraph.ods", "test/files/paragraph.xls", "test/files/paragraph.xlsx", "test/files/paragraph.xml", "test/files/prova.xls", "test/files/ric.ods", "test/files/simple_spreadsheet.ods", "test/files/simple_spreadsheet.xls", "test/files/simple_spreadsheet.xlsx", "test/files/simple_spreadsheet.xml", "test/files/simple_spreadsheet_from_italo.ods", "test/files/simple_spreadsheet_from_italo.xls", "test/files/simple_spreadsheet_from_italo.xml", "test/files/so_datetime.csv", "test/files/style.ods", "test/files/style.xls", "test/files/style.xlsx", "test/files/style.xml", "test/files/time-test.csv", "test/files/time-test.ods", "test/files/time-test.xls", "test/files/time-test.xlsx", "test/files/time-test.xml", "test/files/type_excel.ods", "test/files/type_excel.xlsx", "test/files/type_excelx.ods", "test/files/type_excelx.xls", "test/files/type_openoffice.xls", "test/files/type_openoffice.xlsx", "test/files/whitespace.ods", "test/files/whitespace.xls", "test/files/whitespace.xlsx", "test/files/whitespace.xml", "test/rm_sub_test.rb", "test/rm_test.rb", "test/test_generic_spreadsheet.rb", "test/test_helper.rb", "test/test_roo.rb"]
183
+ s.test_files = ["spec/fixtures/vcr_cassettes/google_drive.yml", "spec/fixtures/vcr_cassettes/google_drive_access_token.yml", "spec/fixtures/vcr_cassettes/google_drive_set.yml", "spec/lib/roo/base_spec.rb", "spec/lib/roo/csv_spec.rb", "spec/lib/roo/excel2003xml_spec.rb", "spec/lib/roo/excel_spec.rb", "spec/lib/roo/excelx/format_spec.rb", "spec/lib/roo/excelx_spec.rb", "spec/lib/roo/google_spec.rb", "spec/lib/roo/libreoffice_spec.rb", "spec/lib/roo/openoffice_spec.rb", "spec/lib/roo/spreadsheet_spec.rb", "spec/spec_helper.rb", "test/all_ss.rb", "test/files/1900_base.xls", "test/files/1900_base.xlsx", "test/files/1904_base.xls", "test/files/1904_base.xlsx", "test/files/Bibelbund.csv", "test/files/Bibelbund.ods", "test/files/Bibelbund.xls", "test/files/Bibelbund.xlsx", "test/files/Bibelbund.xml", "test/files/Bibelbund1.ods", "test/files/Pfand_from_windows_phone.xlsx", "test/files/bad_excel_date.xls", "test/files/bbu.ods", "test/files/bbu.xls", "test/files/bbu.xlsx", "test/files/bbu.xml", "test/files/bode-v1.ods.zip", "test/files/bode-v1.xls.zip", "test/files/boolean.csv", "test/files/boolean.ods", "test/files/boolean.xls", "test/files/boolean.xlsx", "test/files/boolean.xml", "test/files/borders.ods", "test/files/borders.xls", "test/files/borders.xlsx", "test/files/borders.xml", "test/files/bug-numbered-sheet-names.xlsx", "test/files/bug-row-column-fixnum-float.xls", "test/files/bug-row-column-fixnum-float.xml", "test/files/comments.ods", "test/files/comments.xls", "test/files/comments.xlsx", "test/files/csvtypes.csv", "test/files/datetime.ods", "test/files/datetime.xls", "test/files/datetime.xlsx", "test/files/datetime.xml", "test/files/datetime_floatconv.xls", "test/files/datetime_floatconv.xml", "test/files/dreimalvier.ods", "test/files/emptysheets.ods", "test/files/emptysheets.xls", "test/files/emptysheets.xlsx", "test/files/emptysheets.xml", "test/files/excel2003.xml", "test/files/false_encoding.xls", "test/files/false_encoding.xml", "test/files/file_item_error.xlsx", "test/files/formula.ods", "test/files/formula.xls", "test/files/formula.xlsx", "test/files/formula.xml", "test/files/formula_parse_error.xls", "test/files/formula_parse_error.xml", "test/files/formula_string_error.xlsx", "test/files/html-escape.ods", "test/files/link.xls", "test/files/link.xlsx", "test/files/matrix.ods", "test/files/matrix.xls", "test/files/named_cells.ods", "test/files/named_cells.xls", "test/files/named_cells.xlsx", "test/files/no_spreadsheet_file.txt", "test/files/numbers1.csv", "test/files/numbers1.ods", "test/files/numbers1.xls", "test/files/numbers1.xlsx", "test/files/numbers1.xml", "test/files/numeric-link.xlsx", "test/files/only_one_sheet.ods", "test/files/only_one_sheet.xls", "test/files/only_one_sheet.xlsx", "test/files/only_one_sheet.xml", "test/files/paragraph.ods", "test/files/paragraph.xls", "test/files/paragraph.xlsx", "test/files/paragraph.xml", "test/files/prova.xls", "test/files/ric.ods", "test/files/simple_spreadsheet.ods", "test/files/simple_spreadsheet.xls", "test/files/simple_spreadsheet.xlsx", "test/files/simple_spreadsheet.xml", "test/files/simple_spreadsheet_from_italo.ods", "test/files/simple_spreadsheet_from_italo.xls", "test/files/simple_spreadsheet_from_italo.xml", "test/files/so_datetime.csv", "test/files/style.ods", "test/files/style.xls", "test/files/style.xlsx", "test/files/style.xml", "test/files/time-test.csv", "test/files/time-test.ods", "test/files/time-test.xls", "test/files/time-test.xlsx", "test/files/time-test.xml", "test/files/type_excel.ods", "test/files/type_excel.xlsx", "test/files/type_excelx.ods", "test/files/type_excelx.xls", "test/files/type_openoffice.xls", "test/files/type_openoffice.xlsx", "test/files/whitespace.ods", "test/files/whitespace.xls", "test/files/whitespace.xlsx", "test/files/whitespace.xml", "test/rm_sub_test.rb", "test/rm_test.rb", "test/test_generic_spreadsheet.rb", "test/test_helper.rb", "test/test_roo.rb"]
183
184
 
184
185
  if s.respond_to? :specification_version then
185
186
  s.specification_version = 4
@@ -20,4 +20,19 @@ describe Roo::Excelx do
20
20
  end
21
21
  end
22
22
  end
23
+
24
+ describe '#cell' do
25
+ context 'for a link cell' do
26
+ context 'with numeric contents' do
27
+ subject {
28
+ Roo::Excelx.new('test/files/numeric-link.xlsx').cell('A', 1)
29
+ }
30
+
31
+ it 'returns a link with the number as a string value' do
32
+ expect(subject).to be_a(Spreadsheet::Link)
33
+ expect(subject).to eq("8675309.0")
34
+ end
35
+ end
36
+ end
37
+ end
23
38
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: roo
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.13.1
4
+ version: 1.13.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Thomas Preymesser
@@ -205,6 +205,7 @@ files:
205
205
  - test/files/numbers1.xls
206
206
  - test/files/numbers1.xlsx
207
207
  - test/files/numbers1.xml
208
+ - test/files/numeric-link.xlsx
208
209
  - test/files/only_one_sheet.ods
209
210
  - test/files/only_one_sheet.xls
210
211
  - test/files/only_one_sheet.xlsx
@@ -362,6 +363,7 @@ test_files:
362
363
  - test/files/numbers1.xls
363
364
  - test/files/numbers1.xlsx
364
365
  - test/files/numbers1.xml
366
+ - test/files/numeric-link.xlsx
365
367
  - test/files/only_one_sheet.ods
366
368
  - test/files/only_one_sheet.xls
367
369
  - test/files/only_one_sheet.xlsx