From da449cd99a6370721cf44b6115885a299207cfef Mon Sep 17 00:00:00 2001 From: Michael Williamson Date: Thu, 25 Feb 2016 19:12:40 +0000 Subject: Allow italic runs to be configured using style mapping --- tests/conversion_tests.py | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'tests') diff --git a/tests/conversion_tests.py b/tests/conversion_tests.py index 78530a9..8f0a696 100644 --- a/tests/conversion_tests.py +++ b/tests/conversion_tests.py @@ -165,13 +165,22 @@ def bold_runs_can_be_configured_with_style_mapping(): @istest -def italic_runs_are_wrapped_in_emphasis_tags(): +def italic_runs_are_wrapped_in_emphasis_tags_by_default(): result = convert_document_element_to_html( documents.run(children=[documents.text("Hello")], is_italic=True), ) assert_equal("Hello", result.value) +@istest +def italic_runs_can_be_configured_with_style_mapping(): + result = convert_document_element_to_html( + documents.run(children=[documents.text("Hello")], is_italic=True), + style_map=[_style_mapping("i => i")] + ) + assert_equal("Hello", result.value) + + @istest def underline_runs_are_ignored_by_default(): result = convert_document_element_to_html( -- cgit v1.2.3