Commit 906091b5 authored by Ezio Melotti's avatar Ezio Melotti

#22092: use absolute imports in unittest tests. Patch by Vajrasky Kok.

parent a33c8436
...@@ -9,7 +9,7 @@ from test import test_support ...@@ -9,7 +9,7 @@ from test import test_support
import unittest import unittest
from .support import ( from unittest.test.support import (
TestEquality, TestHashing, LoggingResult, ResultWithNoStartTestRunStopTestRun TestEquality, TestHashing, LoggingResult, ResultWithNoStartTestRunStopTestRun
) )
......
...@@ -3,6 +3,7 @@ import re ...@@ -3,6 +3,7 @@ import re
import sys import sys
import unittest import unittest
import unittest.test
class TestDiscovery(unittest.TestCase): class TestDiscovery(unittest.TestCase):
......
import unittest import unittest
from .support import LoggingResult from unittest.test.support import LoggingResult
class Test_FunctionTestCase(unittest.TestCase): class Test_FunctionTestCase(unittest.TestCase):
......
...@@ -3,6 +3,7 @@ from cStringIO import StringIO ...@@ -3,6 +3,7 @@ from cStringIO import StringIO
import os import os
import sys import sys
import unittest import unittest
import unittest.test
class Test_TestProgram(unittest.TestCase): class Test_TestProgram(unittest.TestCase):
......
...@@ -3,7 +3,8 @@ import unittest ...@@ -3,7 +3,8 @@ import unittest
from cStringIO import StringIO from cStringIO import StringIO
import pickle import pickle
from .support import LoggingResult, ResultWithNoStartTestRunStopTestRun from unittest.test.support import (LoggingResult,
ResultWithNoStartTestRunStopTestRun)
class TestCleanUp(unittest.TestCase): class TestCleanUp(unittest.TestCase):
......
import unittest import unittest
from .support import LoggingResult from unittest.test.support import LoggingResult
class Test_TestSkipping(unittest.TestCase): class Test_TestSkipping(unittest.TestCase):
......
import unittest import unittest
import sys import sys
from .support import LoggingResult, TestEquality from unittest.test.support import LoggingResult, TestEquality
### Support code for Test_TestSuite ### Support code for Test_TestSuite
......
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