コード例 #1
0
 def len_fixture(self, request):
     tbl_cxml, expected_len = request.param
     rows = _RowCollection(element(tbl_cxml), None)
     return rows, expected_len
コード例 #2
0
 def iter_fixture(self, request):
     tbl_cxml = request.param
     tbl = element(tbl_cxml)
     rows = _RowCollection(tbl, None)
     expected_row_lst = tbl.findall(qn('a:tr'))
     return rows, expected_row_lst
コード例 #3
0
 def it_raises_on_indexed_access_out_of_range(self):
     rows = _RowCollection(element('a:tbl/a:tr'), None)
     with pytest.raises(IndexError):
         rows[-1]
     with pytest.raises(IndexError):
         rows[9]
コード例 #4
0
ファイル: test_table.py プロジェクト: scanny/python-pptx
 def len_fixture(self, request):
     tbl_cxml, expected_len = request.param
     rows = _RowCollection(element(tbl_cxml), None)
     return rows, expected_len
コード例 #5
0
ファイル: test_table.py プロジェクト: scanny/python-pptx
 def iter_fixture(self, request):
     tbl_cxml = request.param
     tbl = element(tbl_cxml)
     rows = _RowCollection(tbl, None)
     expected_row_lst = tbl.findall(qn("a:tr"))
     return rows, expected_row_lst
コード例 #6
0
ファイル: test_table.py プロジェクト: scanny/python-pptx
 def it_raises_on_indexed_access_out_of_range(self):
     rows = _RowCollection(element("a:tbl/a:tr"), None)
     with pytest.raises(IndexError):
         rows[-1]
     with pytest.raises(IndexError):
         rows[9]