Coverage for tests/test_po2rst.py: 100%

1 from sphinxlint.utils import po2rst

2

3

4 def test_po2rst():

5 po = """msgid "foo"

6 msgstr "bar"

7

8 msgid "test1"

9 msgstr "test2"

10"""

11 rst = """bar

12

13

14 test2

15"""

16 assert po2rst(po) == rst

17

18

19 def test_po2rst_more():

20 po = """msgid "foo"

21 msgstr "bar"

22

23 msgid "test1"

24 msgstr ""

25"test2"

26

27 msgid "test3"

28 msgstr "test4"

29"""

30 rst = """bar

31

32

33 test2

34

35

36

37 test4

38"""

39 assert po2rst(po) == rst