mirror of
https://github.com/python/cpython.git
synced 2025-12-08 06:10:17 +00:00
bpo-40275: Use new test.support helper submodules in tests (GH-21452)
This commit is contained in:
parent
da4e09fff6
commit
604bba1f8f
6 changed files with 62 additions and 54 deletions
|
|
@ -4,7 +4,8 @@
|
|||
#
|
||||
|
||||
from test import support
|
||||
from test.support import TESTFN
|
||||
from test.support import os_helper
|
||||
from test.support.os_helper import TESTFN
|
||||
import unittest, io, codecs, sys
|
||||
import _multibytecodec
|
||||
|
||||
|
|
@ -57,7 +58,7 @@ def test_codingspec(self):
|
|||
code = '# coding: {}\n'.format(enc)
|
||||
exec(code)
|
||||
finally:
|
||||
support.unlink(TESTFN)
|
||||
os_helper.unlink(TESTFN)
|
||||
|
||||
def test_init_segfault(self):
|
||||
# bug #3305: this used to segfault
|
||||
|
|
@ -296,7 +297,7 @@ def test_bug1728403(self):
|
|||
finally:
|
||||
f.close()
|
||||
finally:
|
||||
support.unlink(TESTFN)
|
||||
os_helper.unlink(TESTFN)
|
||||
|
||||
class Test_StreamWriter(unittest.TestCase):
|
||||
def test_gb18030(self):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue