diff options
author | Jesse Luehrs <doy@tozt.net> | 2014-07-05 14:16:19 -0400 |
---|---|---|
committer | Jesse Luehrs <doy@tozt.net> | 2014-07-05 14:16:19 -0400 |
commit | 063a3ed5650df0e84af5ddfc3c909077d04159d5 (patch) | |
tree | fee9aa7b23946e8fe7cd486d8a95f1da1a91ab3f /t | |
parent | a723723da2f4f7155f2f01f42c2502cb65f71b4b (diff) | |
parent | 5bfde2e914636f99e5994c843dd158f6804e5db5 (diff) | |
download | spreadsheet-parsexlsx-063a3ed5650df0e84af5ddfc3c909077d04159d5.tar.gz spreadsheet-parsexlsx-063a3ed5650df0e84af5ddfc3c909077d04159d5.zip |
Merge branch 'pull-25'
Diffstat (limited to 't')
-rw-r--r-- | t/bug-15.t | 2 | ||||
-rw-r--r-- | t/bug-lock.t | 26 | ||||
-rw-r--r-- | t/data/bug-lock.xlsx | bin | 0 -> 8480 bytes |
3 files changed, 27 insertions, 1 deletions
@@ -13,7 +13,7 @@ ok(exists $b2->get_format->{Hidden}); ok(exists $b2->get_format->{Lock}); ok($b2->get_format->{IgnoreProtection}); ok(!$b2->get_format->{Hidden}); -ok(!$b2->get_format->{Lock}); +ok($b2->get_format->{Lock}); my $b3 = $ws->get_cell(2, 1); ok(exists $b3->get_format->{Hidden}); diff --git a/t/bug-lock.t b/t/bug-lock.t new file mode 100644 index 0000000..142d003 --- /dev/null +++ b/t/bug-lock.t @@ -0,0 +1,26 @@ +#!/usr/bin/env perl +use strict; +use warnings; +use Test::More; + +use Spreadsheet::ParseXLSX; + +my $wb = Spreadsheet::ParseXLSX->new->parse('t/data/bug-lock.xlsx'); +my $ws = $wb->worksheet(0); + +my $b1 = $ws->get_cell(0, 0); +ok($b1->get_format->{Lock}); + +my $b2 = $ws->get_cell(1, 0); +ok(!$b2->get_format->{Lock}); + +my $b3 = $ws->get_cell(2, 0); +ok($b3->get_format->{Lock}); + +my $b4 = $ws->get_cell(3, 0); +ok(!$b4->get_format->{Lock}); + +my $b5 = $ws->get_cell(4, 0); +ok($b5->get_format->{Lock}); + +done_testing; diff --git a/t/data/bug-lock.xlsx b/t/data/bug-lock.xlsx Binary files differnew file mode 100644 index 0000000..bf16fdb --- /dev/null +++ b/t/data/bug-lock.xlsx |