def test_split_sheetname(): assert ('', 'B1') == split_sheetname('B1') assert ('sheet', 'B1') == split_sheetname('sheet!B1') assert ('', 'B1:C2') == split_sheetname('B1:C2') assert ('sheet', 'B1:C2') == split_sheetname('sheet!B1:C2') assert ("shee't", 'B1:C2') == split_sheetname("'shee''t'!B1:C2") assert ("shee t", 'B1:C2') == split_sheetname("'shee t'!B1:C2") with pytest.raises(ValueError): split_sheetname('sh!B1', sheet='shx') with pytest.raises(NotImplementedError): split_sheetname('sh!B1:C2:sh2!B1:C2')