Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
cpython
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
cpython
Commits
33315b18
Kaydet (Commit)
33315b18
authored
Eyl 24, 2000
tarafından
Martin v. Löwis
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Use findfile to locate input and output files.
üst
e292a245
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
7 deletions
+7
-7
test_sax.py
Lib/test/test_sax.py
+7
-7
No files found.
Lib/test/test_sax.py
Dosyayı görüntüle @
33315b18
...
...
@@ -7,7 +7,7 @@ from xml.sax.expatreader import create_parser
from
xml.sax.xmlreader
import
InputSource
,
AttributesImpl
,
AttributesNSImpl
from
xml.sax.handler
import
ContentHandler
from
cStringIO
import
StringIO
from
test_support
import
verbose
,
TestFailed
from
test_support
import
verbose
,
TestFailed
,
findfile
# ===== Utilities
...
...
@@ -260,7 +260,7 @@ def test_expat_nsattrs_wattr():
# ===== InputSource support
xml_test_out
=
open
(
"test.xml.out"
)
.
read
()
xml_test_out
=
open
(
findfile
(
"test.xml.out"
)
)
.
read
()
def
test_expat_inpsource_filename
():
parser
=
create_parser
()
...
...
@@ -268,7 +268,7 @@ def test_expat_inpsource_filename():
xmlgen
=
XMLGenerator
(
result
)
parser
.
setContentHandler
(
xmlgen
)
parser
.
parse
(
"test.xml"
)
parser
.
parse
(
findfile
(
"test.xml"
)
)
return
result
.
getvalue
()
==
xml_test_out
...
...
@@ -278,7 +278,7 @@ def test_expat_inpsource_sysid():
xmlgen
=
XMLGenerator
(
result
)
parser
.
setContentHandler
(
xmlgen
)
parser
.
parse
(
InputSource
(
"test.xml"
))
parser
.
parse
(
InputSource
(
findfile
(
"test.xml"
)
))
return
result
.
getvalue
()
==
xml_test_out
...
...
@@ -289,7 +289,7 @@ def test_expat_inpsource_stream():
parser
.
setContentHandler
(
xmlgen
)
inpsrc
=
InputSource
()
inpsrc
.
setByteStream
(
open
(
"test.xml"
))
inpsrc
.
setByteStream
(
open
(
findfile
(
"test.xml"
)
))
parser
.
parse
(
inpsrc
)
return
result
.
getvalue
()
==
xml_test_out
...
...
@@ -445,9 +445,9 @@ def make_test_output():
xmlgen
=
XMLGenerator
(
result
)
parser
.
setContentHandler
(
xmlgen
)
parser
.
parse
(
"test.xml"
)
parser
.
parse
(
findfile
(
"test.xml"
)
)
outf
=
open
(
"test.xml.out"
,
"w"
)
outf
=
open
(
findfile
(
"test.xml.out"
)
,
"w"
)
outf
.
write
(
result
.
getvalue
())
outf
.
close
()
...
...
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