summaryrefslogtreecommitdiff
path: root/docutils/test
diff options
context:
space:
mode:
authorgrubert <grubert@929543f6-e4f2-0310-98a6-ba3bd3dd1d04>2011-04-29 23:20:54 +0000
committergrubert <grubert@929543f6-e4f2-0310-98a6-ba3bd3dd1d04>2011-04-29 23:20:54 +0000
commit36a070a390e613ac0e3eb6c115f3d91de5397eed (patch)
treee7dd136e3421899b8d73c8103ebd45408f863cbc /docutils/test
parent996407ca15e037f6b563f602f030d4c238ef8b4f (diff)
downloaddocutils-36a070a390e613ac0e3eb6c115f3d91de5397eed.tar.gz
* docutils/parsers/rst/directives/misc.py:
- Fix [ 1830389 ] Replace not breaking on getting system_messages from nested_parse git-svn-id: http://svn.code.sf.net/p/docutils/code/trunk@7021 929543f6-e4f2-0310-98a6-ba3bd3dd1d04
Diffstat (limited to 'docutils/test')
-rwxr-xr-xdocutils/test/test_parsers/test_rst/test_directives/test_replace.py11
-rw-r--r--docutils/test/test_parsers/test_rst/test_directives/test_replace_fr.py19
2 files changed, 10 insertions, 20 deletions
diff --git a/docutils/test/test_parsers/test_rst/test_directives/test_replace.py b/docutils/test/test_parsers/test_rst/test_directives/test_replace.py
index 4738fd029..227bb2d7c 100755
--- a/docutils/test/test_parsers/test_rst/test_directives/test_replace.py
+++ b/docutils/test/test_parsers/test_rst/test_directives/test_replace.py
@@ -96,9 +96,6 @@ I recommend you try |Python|_.
["""\
.. |name| replace:: *error in **inline ``markup
""",
-# BUG the "Error in "replace" directive: may contain a single paragraph only."
-# results from Replace.run gets [paragraph, system_massage(s)] from nestet_parse
-# but does not expect.
"""\
<document source="test data">
<system_message ids="id1" level="2" line="1" source="test data" type="WARNING">
@@ -112,10 +109,10 @@ I recommend you try |Python|_.
Inline literal start-string without end-string.
<system_message level="3" line="1" source="test data" type="ERROR">
<paragraph>
- Error in "replace" directive: may contain a single paragraph only.
- <system_message level="2" line="1" source="test data" type="WARNING">
- <paragraph>
- Substitution definition "name" empty or invalid.
+ Substitution definition contains illegal element:
+ <literal_block xml:space="preserve">
+ <problematic ids="id2" refid="id1">
+ *
<literal_block xml:space="preserve">
.. |name| replace:: *error in **inline ``markup
"""],
diff --git a/docutils/test/test_parsers/test_rst/test_directives/test_replace_fr.py b/docutils/test/test_parsers/test_rst/test_directives/test_replace_fr.py
index 68c00fe0b..6847c1c06 100644
--- a/docutils/test/test_parsers/test_rst/test_directives/test_replace_fr.py
+++ b/docutils/test/test_parsers/test_rst/test_directives/test_replace_fr.py
@@ -43,7 +43,6 @@ Le |Na+| est l'ion sodium.
"""],
["""\
Test directive containing english role superscript.
-BUG 1830380: the ERROR is an ERROR and the WARNING a followup to the ERROR
.. |Na+| remplace:: Na\ :sup:`+`
@@ -53,25 +52,19 @@ Le |Na+| est l'ion sodium.
<document source="test data">
<paragraph>
Test directive containing english role superscript.
- BUG 1830380: the ERROR is an ERROR and the WARNING a followup to the ERROR
- <system_message level="1" line="4" source="test data" type="INFO">
+ <system_message level="1" line="3" source="test data" type="INFO">
<paragraph>
No role entry for "sup" in module "docutils.parsers.rst.languages.fr".
Using English fallback for role "sup".
- <system_message level="3" line="4" source="test data" type="ERROR">
- <paragraph>
- Error in "remplace" directive: may contain a single paragraph only.
- <system_message level="2" line="4" source="test data" type="WARNING">
- <paragraph>
- Substitution definition "Na+" empty or invalid.
- <literal_block xml:space="preserve">
- .. |Na+| remplace:: Na\\ :sup:`+`
+ <substitution_definition names="Na+">
+ Na
+ <superscript>
+ +
<paragraph>
Le \n\
<substitution_reference refname="Na+">
Na+
- est l\'ion sodium.
-"""],
+ est l\'ion sodium."""],
]