|
19 | 19 | from .oxml.parts.unitdata.document import a_body |
20 | 20 | from .oxml.unitdata.text import ( |
21 | 21 | a_b, a_bCs, a_br, a_caps, a_cs, a_dstrike, a_p, a_pPr, a_pStyle, |
22 | | - a_shadow, a_smallCaps, a_snapToGrid, a_specVanish, a_strike, a_t, a_u, |
23 | | - a_vanish, a_webHidden, an_emboss, an_i, an_iCs, an_imprint, an_oMath, |
24 | | - a_noProof, an_outline, an_r, an_rPr, an_rStyle, an_rtl |
| 22 | + a_shadow, a_smallCaps, a_snapToGrid, a_specVanish, a_strike, a_t, a_tab, |
| 23 | + a_u, a_vanish, a_webHidden, an_emboss, an_i, an_iCs, an_imprint, |
| 24 | + an_oMath, a_noProof, an_outline, an_r, an_rPr, an_rStyle, an_rtl |
25 | 25 | ) |
26 | 26 | from .unitutil import call, class_mock, instance_mock, Mock |
27 | 27 |
|
@@ -207,6 +207,11 @@ def it_can_add_a_break(self, add_break_fixture): |
207 | 207 | run.add_break(break_type) |
208 | 208 | assert run._r.xml == expected_xml |
209 | 209 |
|
| 210 | + def it_can_add_a_tab(self, add_tab_fixture): |
| 211 | + run, expected_xml = add_tab_fixture |
| 212 | + run.add_tab() |
| 213 | + assert run._r.xml == expected_xml |
| 214 | + |
210 | 215 | def it_knows_the_text_it_contains(self, text_prop_fixture): |
211 | 216 | run, expected_text = text_prop_fixture |
212 | 217 | assert run.text == expected_text |
@@ -241,6 +246,11 @@ def add_break_fixture(self, request, run): |
241 | 246 | expected_xml = an_r().with_nsdecls().with_child(br_bldr).xml() |
242 | 247 | return run, break_type, expected_xml |
243 | 248 |
|
| 249 | + @pytest.fixture |
| 250 | + def add_tab_fixture(self, run): |
| 251 | + expected_xml = an_r().with_nsdecls().with_child(a_tab()).xml() |
| 252 | + return run, expected_xml |
| 253 | + |
244 | 254 | @pytest.fixture(params=['foobar', ' foo bar', 'bar foo ']) |
245 | 255 | def add_text_fixture(self, request, run, Text_): |
246 | 256 | text_str = request.param |
|
0 commit comments