Commit 4b73d897 authored by Sven Franck's avatar Sven Franck

erp5_corporate_identitiy: try to fix missing translation and svg image comparison failing tests

parent f48ad28b
...@@ -39,7 +39,7 @@ ...@@ -39,7 +39,7 @@
</item> </item>
<item> <item>
<key> <string>_EtagSupport__etag</string> </key> <key> <string>_EtagSupport__etag</string> </key>
<value> <string>ts13613456.99</string> </value> <value> <string>ts13676932.13</string> </value>
</item> </item>
<item> <item>
<key> <string>_Modify_portal_content_Permission</string> </key> <key> <string>_Modify_portal_content_Permission</string> </key>
...@@ -83,7 +83,7 @@ ...@@ -83,7 +83,7 @@
</item> </item>
<item> <item>
<key> <string>content_md5</string> </key> <key> <string>content_md5</string> </key>
<value> <string>903f474be052e6b81e9a2868a45ebb5b</string> </value> <value> <string>37124d8f30168b637379ff75a8c56096</string> </value>
</item> </item>
<item> <item>
<key> <string>content_type</string> </key> <key> <string>content_type</string> </key>
......
...@@ -39,7 +39,7 @@ ...@@ -39,7 +39,7 @@
</item> </item>
<item> <item>
<key> <string>_EtagSupport__etag</string> </key> <key> <string>_EtagSupport__etag</string> </key>
<value> <string>ts13613484.66</string> </value> <value> <string>ts13676955.42</string> </value>
</item> </item>
<item> <item>
<key> <string>_Modify_portal_content_Permission</string> </key> <key> <string>_Modify_portal_content_Permission</string> </key>
...@@ -83,7 +83,7 @@ ...@@ -83,7 +83,7 @@
</item> </item>
<item> <item>
<key> <string>content_md5</string> </key> <key> <string>content_md5</string> </key>
<value> <string>8b09f2215c971b76ff549d92d17ab4ab</string> </value> <value> <string>2bbd525d065612d63e5110e9db2a9e16</string> </value>
</item> </item>
<item> <item>
<key> <string>content_type</string> </key> <key> <string>content_type</string> </key>
......
...@@ -39,7 +39,7 @@ ...@@ -39,7 +39,7 @@
</item> </item>
<item> <item>
<key> <string>_EtagSupport__etag</string> </key> <key> <string>_EtagSupport__etag</string> </key>
<value> <string>ts13613503.43</string> </value> <value> <string>ts13676973.16</string> </value>
</item> </item>
<item> <item>
<key> <string>_Modify_portal_content_Permission</string> </key> <key> <string>_Modify_portal_content_Permission</string> </key>
...@@ -83,7 +83,7 @@ ...@@ -83,7 +83,7 @@
</item> </item>
<item> <item>
<key> <string>content_md5</string> </key> <key> <string>content_md5</string> </key>
<value> <string>5707f11ee910ba779be0d6da34e16960</string> </value> <value> <string>cd1fdc9a1c66e4f4fef4ee72f7ccdfe3</string> </value>
</item> </item>
<item> <item>
<key> <string>content_type</string> </key> <key> <string>content_type</string> </key>
......
...@@ -79,7 +79,7 @@ ...@@ -79,7 +79,7 @@
</item> </item>
<item> <item>
<key> <string>content_md5</string> </key> <key> <string>content_md5</string> </key>
<value> <string>6db10f6aa77ec08b289005d54dd36e65</string> </value> <value> <string>558046d1290e00487a9835ee0e6d440c</string> </value>
</item> </item>
<item> <item>
<key> <string>content_type</string> </key> <key> <string>content_type</string> </key>
...@@ -99,7 +99,7 @@ ...@@ -99,7 +99,7 @@
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>template_test_book_input_page_9_002_en_bmp</string> </value> <value> <string>template_test_book_input_page_10_002_en_bmp</string> </value>
</item> </item>
<item> <item>
<key> <string>language</string> </key> <key> <string>language</string> </key>
......
...@@ -84,9 +84,6 @@ ...@@ -84,9 +84,6 @@
<!--tal:block tal:condition="python: book_include_reference is not None">
<tal:block metal:use-macro="context/WebPage_createBookTableOfReferences/macros/book_references" />
</tal:block-->
<h1>Synthese</h1> <h1>Synthese</h1>
<p>This document is a high level overview measures taken by Foo for Bar project. </p> <p>This document is a high level overview measures taken by Foo for Bar project. </p>
......
...@@ -170,10 +170,7 @@ ...@@ -170,10 +170,7 @@
<section class="ci-book-table-of-content"><p class="ci-book-toc-faux-h1" i18n:translate="" i18n:domain="erp5_ui">Table of Contents</p><ol><li><div><a href="#introduction">Introduction</div></a><ol><li><div><a href="#references">References</div></a><ol><li><div><a href="#applicable-documents">Applicable Documents</div></a></li><li><div><a href="#referenced-documents">Referenced Documents</div></a></li></ol><li><div><a href="#abbreviations">Abbreviations</div></a></li><li><div><a href="#figures">Figures</div></a></li><li><div><a href="#tables">Tables</div></a></li></ol><li><div><a href="#synthese">Synthese</div></a><ol><li><div><a href="#risks-and-measures">Risks and measures</div></a><ol><li><div><a href="#risk-of-casualties-if-device-does-not-stop-and-destroys-itself">Risk of casualties if device does not stop and destroys itself</div></a></li><li><div><a href="#risk-of-killing-birds-and-polluting-the-environment">Risk of killing birds and polluting the environment</div></a></li><li><div><a href="#noise-and-vibration-levels">Noise and vibration levels</div></a></li></ol></li></ol><li><div><a href="#header-embedded-document">Header Embedded Document</div></a><ol><li><div><a href="#header-embedded-document-content-examples">Header Embedded Document content Examples</div></a></li></ol><li><div><a href="#reports">Reports</div></a><ol><li><div><a href="#project-reports">Project Reports</div></a></li><li><div><a href="#sale-order-reports">Sale Order Reports</div></a></ol></ol></section> <section class="ci-book-table-of-content"><p class="ci-book-toc-faux-h1">Table of Contents</p><ol><li><div><a href="#introduction">Introduction</div></a><ol><li><div><a href="#references">References</div></a><ol><li><div><a href="#applicable-documents">Applicable Documents</div></a></li><li><div><a href="#referenced-documents">Referenced Documents</div></a></li></ol><li><div><a href="#abbreviations">Abbreviations</div></a></li><li><div><a href="#figures">Figures</div></a></li><li><div><a href="#tables">Tables</div></a></li></ol><li><div><a href="#synthese">Synthese</div></a><ol><li><div><a href="#risks-and-measures">Risks and measures</div></a><ol><li><div><a href="#risk-of-casualties-if-device-does-not-stop-and-destroys-itself">Risk of casualties if device does not stop and destroys itself</div></a></li><li><div><a href="#risk-of-killing-birds-and-polluting-the-environment">Risk of killing birds and polluting the environment</div></a></li><li><div><a href="#noise-and-vibration-levels">Noise and vibration levels</div></a></li></ol></li></ol><li><div><a href="#header-embedded-document">Header Embedded Document</div></a><ol><li><div><a href="#header-embedded-document-content-examples">Header Embedded Document content Examples</div></a></li></ol><li><div><a href="#reports">Reports</div></a><ol><li><div><a href="#project-reports">Project Reports</div></a></li><li><div><a href="#sale-order-reports">Sale Order Reports</div></a></ol></ol></section>
<!--tal:block tal:condition="python: book_include_reference is not None">
<tal:block metal:use-macro="context/WebPage_createBookTableOfReferences/macros/book_references" />
</tal:block-->
<h1><a name="introduction"></a>Introduction<a class="custom-para" href="https://softinst73908.host.vifib.net/erp5/web_page_module/template_test_book_input_001_en_html#introduction"><span style="font-size:.75em;line-height:1em;padding-left:.5em;">&para;</span></a></h1> <h1><a name="introduction"></a>Introduction<a class="custom-para" href="https://softinst73908.host.vifib.net/erp5/web_page_module/template_test_book_input_001_en_html#introduction"><span style="font-size:.75em;line-height:1em;padding-left:.5em;">&para;</span></a></h1>
<h2><a name="references"></a>References<a class="custom-para" href="https://softinst73908.host.vifib.net/erp5/web_page_module/template_test_book_input_001_en_html#references"><span style="font-size:.75em;line-height:1em;padding-left:.5em;">&para;</span></a></h2> <h2><a name="references"></a>References<a class="custom-para" href="https://softinst73908.host.vifib.net/erp5/web_page_module/template_test_book_input_001_en_html#references"><span style="font-size:.75em;line-height:1em;padding-left:.5em;">&para;</span></a></h2>
......
...@@ -83,10 +83,7 @@ ...@@ -83,10 +83,7 @@
<section class="ci-book-table-of-content"><p class="ci-book-toc-faux-h1" i18n:translate="" i18n:domain="erp5_ui">Inhaltsverzeichnis</p><ol><li><div><a href="#synthese">Synthese</div></a><ol><li><div><a href="#risks-and-measures">Risks and measures</div></a><ol><li><div><a href="#risk-of-casualties-if-device-does-not-stop-and-destroys-itself">Risk of casualties if device does not stop and destroys itself</div></a></li><li><div><a href="#risk-of-killing-birds-and-polluting-the-environment">Risk of killing birds and polluting the environment</div></a></li><li><div><a href="#noise-and-vibration-levels">Noise and vibration levels</div></a></li></ol></li></ol><li><div><a href="#reports">Reports</div></a><ol><li><div><a href="#project-reports">Project Reports</div></a></li><li><div><a href="#sale-order-reports">Sale Order Reports</div></a></ol></ol></section> <section class="ci-book-table-of-content"><p class="ci-book-toc-faux-h1">Inhaltsverzeichnis</p><ol><li><div><a href="#synthese">Synthese</div></a><ol><li><div><a href="#risks-and-measures">Risks and measures</div></a><ol><li><div><a href="#risk-of-casualties-if-device-does-not-stop-and-destroys-itself">Risk of casualties if device does not stop and destroys itself</div></a></li><li><div><a href="#risk-of-killing-birds-and-polluting-the-environment">Risk of killing birds and polluting the environment</div></a></li><li><div><a href="#noise-and-vibration-levels">Noise and vibration levels</div></a></li></ol></li></ol><li><div><a href="#reports">Reports</div></a><ol><li><div><a href="#project-reports">Project Reports</div></a></li><li><div><a href="#sale-order-reports">Sale Order Reports</div></a></ol></ol></section>
<!--tal:block tal:condition="python: book_include_reference is not None">
<tal:block metal:use-macro="context/WebPage_createBookTableOfReferences/macros/book_references" />
</tal:block-->
<h1><a name="synthese"></a>Synthese<a class="custom-para" href="https://softinst73908.host.vifib.net/erp5/web_page_module/template_test_book_input_002_de_html#synthese"><span style="font-size:.75em;line-height:1em;padding-left:.5em;">&para;</span></a></h1> <h1><a name="synthese"></a>Synthese<a class="custom-para" href="https://softinst73908.host.vifib.net/erp5/web_page_module/template_test_book_input_002_de_html#synthese"><span style="font-size:.75em;line-height:1em;padding-left:.5em;">&para;</span></a></h1>
<p>This document is a high level overview measures taken by Foo for Bar project. </p> <p>This document is a high level overview measures taken by Foo for Bar project. </p>
......
...@@ -60,7 +60,7 @@ for header in re.findall("<h[1-6].*?</h[1-6]>", doc_content or blank): ...@@ -60,7 +60,7 @@ for header in re.findall("<h[1-6].*?</h[1-6]>", doc_content or blank):
closer = int(header_current) * '</ol>' closer = int(header_current) * '</ol>'
insert = ''.join([ insert = ''.join([
'<section class="ci-book-table-of-content">', '<section class="ci-book-table-of-content">',
'<p class="ci-book-toc-faux-h1" i18n:translate="" i18n:domain="erp5_ui">%s</p>' % (doc_toc_title or "Table of Contents"), '<p class="ci-book-toc-faux-h1">%s</p>' % (doc_toc_title or "XXX"),
table_of_content, table_of_content,
closer, closer,
'</section>' '</section>'
......
...@@ -65,9 +65,6 @@ Generates the complete book (only called in HTML version) ...@@ -65,9 +65,6 @@ Generates the complete book (only called in HTML version)
<tal:block metal:use-macro="context/WebPage_createBookTableOfHistory/macros/book_history" /> <tal:block metal:use-macro="context/WebPage_createBookTableOfHistory/macros/book_history" />
</tal:block> </tal:block>
<tal:block tal:replace="structure book_table_of_content"></tal:block> <tal:block tal:replace="structure book_table_of_content"></tal:block>
<!--tal:block tal:condition="python: book_include_reference is not None">
<tal:block metal:use-macro="context/WebPage_createBookTableOfReferences/macros/book_references" />
</tal:block-->
<tal:block metal:use-macro="context/WebPage_createBookContent/macros/book_content" /> <tal:block metal:use-macro="context/WebPage_createBookContent/macros/book_content" />
<tal:block metal:use-macro="context/WebPage_createBookFooter/macros/book_footer" /> <tal:block metal:use-macro="context/WebPage_createBookFooter/macros/book_footer" />
</body> </body>
......
...@@ -237,7 +237,8 @@ if book_include_reference_table is not None: ...@@ -237,7 +237,8 @@ if book_include_reference_table is not None:
if book_format == 'html' or book_format == 'mhtml': if book_format == 'html' or book_format == 'mhtml':
book_content = book_references.encode('utf-8').strip() + book_content book_content = book_references.encode('utf-8').strip() + book_content
# table of content # table of content has to be created manually to run over everything that
# should be indexed in the toc
if book_include_content_table is not None: if book_include_content_table is not None:
book_translated_toc_title = translateText("Table of Contents") book_translated_toc_title = translateText("Table of Contents")
if book_format == "pdf": if book_format == "pdf":
......
...@@ -988,7 +988,7 @@ class TestCorporateIdentityTemplates(ERP5TypeTestCase): ...@@ -988,7 +988,7 @@ class TestCorporateIdentityTemplates(ERP5TypeTestCase):
self.runPdfTestPattern( self.runPdfTestPattern(
"template_test_book_input_001_en_html", "template_test_book_input_001_en_html",
"template_test_book_input_page_4_002_en_bmp", "template_test_book_input_page_4_002_en_bmp",
"template_test_book_input_001_en_pdf", "template_test_book_input_002_en_pdf",
**dict( **dict(
page_number=4, page_number=4,
format="pdf", format="pdf",
...@@ -1023,7 +1023,7 @@ class TestCorporateIdentityTemplates(ERP5TypeTestCase): ...@@ -1023,7 +1023,7 @@ class TestCorporateIdentityTemplates(ERP5TypeTestCase):
self.runPdfTestPattern( self.runPdfTestPattern(
"template_test_book_input_001_en_html", "template_test_book_input_001_en_html",
"template_test_book_input_page_5_002_en_bmp", "template_test_book_input_page_5_002_en_bmp",
"template_test_book_input_001_en_pdf", "template_test_book_input_002_en_pdf",
**dict( **dict(
page_number=5, page_number=5,
format="pdf", format="pdf",
...@@ -1046,7 +1046,7 @@ class TestCorporateIdentityTemplates(ERP5TypeTestCase): ...@@ -1046,7 +1046,7 @@ class TestCorporateIdentityTemplates(ERP5TypeTestCase):
) )
) )
# duplicate, just for page 9 # duplicate, just for page 10
@changeSkin('Book') @changeSkin('Book')
def testpdfBookAllOptionsDoubleDupe(self): def testpdfBookAllOptionsDoubleDupe(self):
""" """
...@@ -1057,10 +1057,10 @@ class TestCorporateIdentityTemplates(ERP5TypeTestCase): ...@@ -1057,10 +1057,10 @@ class TestCorporateIdentityTemplates(ERP5TypeTestCase):
""" """
self.runPdfTestPattern( self.runPdfTestPattern(
"template_test_book_input_001_en_html", "template_test_book_input_001_en_html",
"template_test_book_input_page_9_002_en_bmp", "template_test_book_input_page_10_002_en_bmp",
"template_test_book_input_001_en_pdf", "template_test_book_input_002_en_pdf",
**dict( **dict(
page_number=9, page_number=10,
format="pdf", format="pdf",
use_skin="Book", use_skin="Book",
test_method="WebPage_exportAsBook", test_method="WebPage_exportAsBook",
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="Test Component" module="erp5.portal_type"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_recorded_property_dict</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
</item>
<item>
<key> <string>default_reference</string> </key>
<value> <string>testCorporateIdentityTemplatesDump</string> </value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string>Test to dump mhtml passed into cloudooo</string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>test.erp5.testCorporateIdentityTemplatesDump</string> </value>
</item>
<item>
<key> <string>portal_type</string> </key>
<value> <string>Test Component</string> </value>
</item>
<item>
<key> <string>sid</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>text_content_error_message</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>text_content_warning_message</string> </key>
<value>
<tuple>
<string>W: 30, 0: Unused createZODBPythonScript imported from Products.ERP5Type.tests.utils (unused-import)</string>
<string>W: 32, 0: Unused import transaction (unused-import)</string>
<string>W: 33, 0: Unused import functools (unused-import)</string>
</tuple>
</value>
</item>
<item>
<key> <string>version</string> </key>
<value> <string>erp5</string> </value>
</item>
<item>
<key> <string>workflow_history</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record id="2" aka="AAAAAAAAAAI=">
<pickle>
<global name="PersistentMapping" module="Persistence.mapping"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>data</string> </key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</pickle>
</record>
<record id="3" aka="AAAAAAAAAAM=">
<pickle>
<global name="PersistentMapping" module="Persistence.mapping"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>data</string> </key>
<value>
<dictionary>
<item>
<key> <string>component_validation_workflow</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAQ=</string> </persistent>
</value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
<record id="4" aka="AAAAAAAAAAQ=">
<pickle>
<global name="WorkflowHistoryList" module="Products.ERP5Type.patches.WorkflowTool"/>
</pickle>
<pickle>
<tuple>
<none/>
<list>
<dictionary>
<item>
<key> <string>action</string> </key>
<value> <string>validate</string> </value>
</item>
<item>
<key> <string>validation_state</string> </key>
<value> <string>validated</string> </value>
</item>
</dictionary>
</list>
</tuple>
</pickle>
</record>
</ZopeData>
...@@ -6,5 +6,5 @@ organisation_module/template_test*/default** ...@@ -6,5 +6,5 @@ organisation_module/template_test*/default**
person_module/template_test* person_module/template_test*
person_module/template_test*/default** person_module/template_test*/default**
portal_preferences/default_site_preference/template_* portal_preferences/default_site_preference/template_*
portal_preferences/default_site_preference/template_* portal_tests/template_zuite/testAndUpdateTest*
web_page_module/template_test_* web_page_module/template_test_*
\ No newline at end of file
...@@ -6,5 +6,5 @@ organisation_module/template_test*/default** ...@@ -6,5 +6,5 @@ organisation_module/template_test*/default**
person_module/template_test* person_module/template_test*
person_module/template_test*/default** person_module/template_test*/default**
portal_preferences/default_site_preference/template_* portal_preferences/default_site_preference/template_*
portal_preferences/default_site_preference/template_* portal_tests/template_zuite/testAndUpdateTest*
web_page_module/template_test_* web_page_module/template_test_*
\ No newline at end of file
test.erp5.testCorporateIdentityTemplates test.erp5.testCorporateIdentityTemplates
test.erp5.testCorporateIdentityTemplatesDump
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment