Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitf4aff64

Browse files
committed
Test pxdom treebuilder/walker. See html5lib-discuss for information on the failures/errors this causes.
--HG--extra : convert_revision : svn%3Aacbfec75-9323-0410-a652-858a13e371e0/trunk%401100
1 parent3c9fc21 commitf4aff64

File tree

2 files changed

+18
-0
lines changed

2 files changed

+18
-0
lines changed

‎tests/test_parser.py‎

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,14 @@
5050
exceptImportError:
5151
pass
5252

53+
#Try whatever dom implementations are avaliable from a list that are
54+
#"supposed" to work
55+
try:
56+
importpxdom
57+
treeTypes["pxdom"]=treebuilders.getTreeBuilder("dom",pxdom)
58+
exceptImportError:
59+
pass
60+
5361
#Run the parse error checks
5462
checkParseErrors=False# TODO
5563

‎tests/test_treewalkers.py‎

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,16 @@ def PullDOMAdapter(node):
9494
"walker":treewalkers.getTreeWalker("beautifulsoup")}
9595
exceptImportError:
9696
pass
97+
98+
#Try whatever etree implementations are available from a list that are
99+
#"supposed" to work
100+
try:
101+
importpxdom
102+
treeTypes['pxdom']= \
103+
{"builder":treebuilders.getTreeBuilder("dom",pxdom),
104+
"walker":treewalkers.getTreeWalker("dom")}
105+
exceptImportError:
106+
pass
97107

98108
try:
99109
fromgenshi.coreimportQName,Attrs

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp