Exemple #1
0
 def test_series(self):
     s = Sheet(self.data, "test")
     s.name_columns_by_row(2)
     eq_(s.colnames, ["Column 1", "Column 2", "Column 3"])
     custom_columns = ["C1", "C2", "C3"]
     s.colnames = custom_columns
     eq_(s.colnames, custom_columns)
Exemple #2
0
 def test_series(self):
     s = Sheet(self.data, "test")
     s.name_columns_by_row(2)
     assert s.colnames == ["Column 1", "Column 2", "Column 3"]
     custom_columns = ["C1", "C2", "C3"]
     s.colnames = custom_columns
     assert s.colnames == custom_columns
Exemple #3
0
 def test_column_names2(self):
     data = [
         [1, 2, 3],
         [4, 5, 6],
         [7, 8, 9]
     ]
     sheet = Sheet(data)
     sheet.colnames = ["Column", "Column", "Column"]
     assert sheet.colnames == ["Column", "Column-1", "Column-2"]
Exemple #4
0
 def test_column_names2(self):
     data = [[1, 2, 3], [4, 5, 6], [7, 8, 9]]
     sheet = Sheet(data)
     sheet.colnames = ["Column", "Column", "Column"]
     assert sheet.colnames == ["Column", "Column-1", "Column-2"]