Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Georgios Dagkakis
erp5
Commits
cc1f687f
Commit
cc1f687f
authored
Sep 30, 2022
by
Jérome Perrin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
run_my_doc: strip unnecessary whitespace in generated zelenium tests
parent
2ed3c9e0
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
68 additions
and
68 deletions
+68
-68
bt5/erp5_run_my_doc/ExtensionTemplateItem/portal_components/extension.erp5.ERP5RunMyDocs.py
...ateItem/portal_components/extension.erp5.ERP5RunMyDocs.py
+1
-1
bt5/erp5_run_my_doc/TestTemplateItem/portal_components/test.erp5.testRunMyDoc.py
...tTemplateItem/portal_components/test.erp5.testRunMyDoc.py
+67
-67
No files found.
bt5/erp5_run_my_doc/ExtensionTemplateItem/portal_components/extension.erp5.ERP5RunMyDocs.py
View file @
cc1f687f
...
@@ -77,7 +77,7 @@ def extractTest(text):
...
@@ -77,7 +77,7 @@ def extractTest(text):
testcode
+=
row
[
0
].
text
testcode
+=
row
[
0
].
text
else
:
else
:
testcode
+=
lxml
.
html
.
tostring
(
row
)
testcode
+=
lxml
.
html
.
tostring
(
row
)
return
testcode
return
testcode
.
strip
()
"""
"""
HTML5 Presentation validador
HTML5 Presentation validador
...
...
bt5/erp5_run_my_doc/TestTemplateItem/portal_components/test.erp5.testRunMyDoc.py
View file @
cc1f687f
...
@@ -34,7 +34,7 @@ class TestRunMyDoc(ERP5TypeTestCase):
...
@@ -34,7 +34,7 @@ class TestRunMyDoc(ERP5TypeTestCase):
"""
"""
Basic Test for internal implementation of RunMyDocs
Basic Test for internal implementation of RunMyDocs
"""
"""
maxDiff
=
None
def
getTitle
(
self
):
def
getTitle
(
self
):
return
"Run My Doc"
return
"Run My Doc"
...
@@ -141,37 +141,37 @@ class TestRunMyDoc(ERP5TypeTestCase):
...
@@ -141,37 +141,37 @@ class TestRunMyDoc(ERP5TypeTestCase):
Test the script that extracts Selenium Test from HTML body.
Test the script that extracts Selenium Test from HTML body.
"""
"""
test_page_html
=
"""<section><h1>TITLE</h1><details>DETAILS<details>
test_page_html
=
"""<section><h1>TITLE</h1><details>DETAILS<details>
<test><table class="test" style="display: none;"> <tbody> </tbody></table> </test>
<test><table class="test" style="display: none;"> <tbody> </tbody></table> </test>
</section>
</section>
<section><h1>TITLE</h1><details>DETAILS<details><test>
<section><h1>TITLE</h1><details>DETAILS<details><test>
<table class="test" style="display: none;">
<table class="test" style="display: none;">
<tbody>
<tbody>
<tr>
<tr>
<td colspan="3"><span metal:use-macro="container/Zuite_viewTestMacroLibrary/macros/init_test_environment" style="display: none;">init</span></td>
<td colspan="3"><span metal:use-macro="container/Zuite_viewTestMacroLibrary/macros/init_test_environment" style="display: none;">init</span></td>
</tr>
</tr>
<tr>
<tr>
<td>selectAndWait</td>
<td>selectAndWait</td>
<td>name=select_module</td>
<td>name=select_module</td>
<td>label=Test Pages</td>
<td>label=Test Pages</td>
</tr>
</tr>
<tr>
<tr>
<td>verifyTextPresent</td>
<td>verifyTextPresent</td>
<td>Test Pages</td>
<td>Test Pages</td>
<td> <br /> </td>
<td> <br /> </td>
</tr>
</tr>
<tr style="opacity: 1;">
<tr style="opacity: 1;">
<td>clickAndWait</td>
<td>clickAndWait</td>
<td>css=a.fast_input > span.image</td>
<td>css=a.fast_input > span.image</td>
<td> <br /> </td>
<td> <br /> </td>
</tr> </tbody></table> </test>
</tr> </tbody></table> </test>
</section>
</section>
<section><h1>TITLE</h1><details>DETAILS<details><test>
<section><h1>TITLE</h1><details>DETAILS<details><test>
<table class="test" style="display: none;"> <tbody>
<table class="test" style="display: none;"> <tbody>
<tr>
<tr>
<td>verifyTextPresent</td>
<td>verifyTextPresent</td>
<td>Test Pages</td>
<td>Test Pages</td>
<td> <br /> </td>
<td> <br /> </td>
</tr> </tbody></table> </test>
</tr> </tbody></table> </test>
</section>"""
</section>"""
expected_test_html
=
u"""<html>
expected_test_html
=
u"""<html>
...
@@ -198,25 +198,25 @@ class TestRunMyDoc(ERP5TypeTestCase):
...
@@ -198,25 +198,25 @@ class TestRunMyDoc(ERP5TypeTestCase):
<td>%s</td>
<td>%s</td>
<td>base_password</td>
<td>base_password</td>
</tr>
</tr>
<span metal:use-macro="container/Zuite_viewTestMacroLibrary/macros/init_test_environment" style="display: none;">init</span><tr>
<span metal:use-macro="container/Zuite_viewTestMacroLibrary/macros/init_test_environment" style="display: none;">init</span><tr>
<td>selectAndWait</td>
<td>selectAndWait</td>
<td>name=select_module</td>
<td>name=select_module</td>
<td>label=Test Pages</td>
<td>label=Test Pages</td>
</tr>
</tr>
<tr>
<tr>
<td>verifyTextPresent</td>
<td>verifyTextPresent</td>
<td>Test Pages</td>
<td>Test Pages</td>
<td> <br> </td>
<td> <br> </td>
</tr>
</tr>
<tr style="opacity: 1;">
<tr style="opacity: 1;">
<td>clickAndWait</td>
<td>clickAndWait</td>
<td>css=a.fast_input > span.image</td>
<td>css=a.fast_input > span.image</td>
<td> <br> </td>
<td> <br> </td>
</tr> <tr>
</tr> <tr>
<td>verifyTextPresent</td>
<td>verifyTextPresent</td>
<td>Test Pages</td>
<td>Test Pages</td>
<td> <br> </td>
<td> <br> </td>
</tr>
</tr>
</tbody>
</tbody>
</table>
</table>
</body>
</body>
...
@@ -270,25 +270,25 @@ class TestRunMyDoc(ERP5TypeTestCase):
...
@@ -270,25 +270,25 @@ class TestRunMyDoc(ERP5TypeTestCase):
<td>%s</td>
<td>%s</td>
<td>base_password</td>
<td>base_password</td>
</tr>
</tr>
<span metal:use-macro="container/Zuite_viewTestMacroLibrary/macros/init_test_environment" style="display: none;">init</span><tr>
<span metal:use-macro="container/Zuite_viewTestMacroLibrary/macros/init_test_environment" style="display: none;">init</span><tr>
<td>selectAndWait</td>
<td>selectAndWait</td>
<td>name=select_module</td>
<td>name=select_module</td>
<td>label=Test Pages</td>
<td>label=Test Pages</td>
</tr>
</tr>
<tr>
<tr>
<td>verifyTextPresent</td>
<td>verifyTextPresent</td>
<td>Test Pages</td>
<td>Test Pages</td>
<td> <br> </td>
<td> <br> </td>
</tr>
</tr>
<tr style="opacity: 1;">
<tr style="opacity: 1;">
<td>clickAndWait</td>
<td>clickAndWait</td>
<td>css=a.fast_input > span.image</td>
<td>css=a.fast_input > span.image</td>
<td> <br> </td>
<td> <br> </td>
</tr> <tr>
</tr> <tr>
<td>verifyTextPresent</td>
<td>verifyTextPresent</td>
<td>Test Pages</td>
<td>Test Pages</td>
<td> <br> </td>
<td> <br> </td>
</tr>
</tr>
</tbody>
</tbody>
</table>
</table>
</body>
</body>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment