File tree Expand file tree Collapse file tree 1 file changed +25
-0
lines changed
tests/PhpSpreadsheetTests/Reader/Xlsx Expand file tree Collapse file tree 1 file changed +25
-0
lines changed Original file line number Diff line number Diff line change @@ -77,4 +77,29 @@ public function testListWorksheetNamesNamespace(): void
77
77
78
78
self ::assertEquals ($ expected , $ actual );
79
79
}
80
+
81
+ public function testListWorksheetNamesChartSheet (): void
82
+ {
83
+ $ filename = 'tests/data/Reader/XLSX/ChartSheet.xlsx ' ;
84
+ $ reader = new Xlsx ();
85
+ $ actual = $ reader ->listWorksheetNames ($ filename );
86
+
87
+ $ expected = ['Sheet1 ' , 'Chart1 ' ];
88
+
89
+ self ::assertEquals ($ expected , $ actual );
90
+ }
91
+
92
+ public function testListWorksheetInfoChartSheet (): void
93
+ {
94
+ $ filename = 'tests/data/Reader/XLSX/ChartSheet.xlsx ' ;
95
+ $ reader = new Xlsx ();
96
+ $ actual = $ reader ->listWorksheetInfo ($ filename );
97
+
98
+ $ chartSheetInfo = $ actual [1 ];
99
+
100
+ self ::assertSame ('Chart1 ' , $ chartSheetInfo ['worksheetName ' ]);
101
+ self ::assertSame (-1 , $ chartSheetInfo ['lastColumnIndex ' ]);
102
+ self ::assertSame (0 , $ chartSheetInfo ['totalRows ' ]);
103
+ self ::assertSame (0 , $ chartSheetInfo ['totalColumns ' ]);
104
+ }
80
105
}
You can’t perform that action at this time.
0 commit comments