Skip to content

Commit fd11855

Browse files
authored
Use separate test directories per framework (#983)
* Use separate test directories per framework * Remove odd characters in test subdirectory names * Separate test dir for non-CLI test runs
1 parent 906d46d commit fd11855

2 files changed

Lines changed: 8 additions & 5 deletions

File tree

Src/IronPython/Lib/iptest/ipunittest.py

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -111,16 +111,19 @@ def load_ironpython_test(*args):
111111
class IronPythonTestCase(unittest.TestCase, FileUtil, ProcessUtil):
112112

113113
def setUp(self):
114-
self._temporary_dir = os.path.join(self.temp_dir, "IronPython")
114+
if is_cli:
115+
self._temporary_dir = os.path.join(self.temp_dir, "IronPythonTest", clr.TargetFramework.translate(str.maketrans(" =,", "__-")))
116+
else:
117+
self._temporary_dir = os.path.join(self.temp_dir, "IronPythonTest", "CPython")
115118
self.ensure_directory_present(self._temporary_dir)
116-
119+
117120
self._iron_python_test_dll = _iron_python_test_dll
118121
self._test_dir = os.path.join(_root, 'Tests')
119122
self._test_inputs_dir = os.path.join(_root, 'Tests', 'Inputs')
120123

121124
def add_reference_to_dlr_core(self):
122125
_add_reference_to_dlr_core()
123-
126+
124127
def load_iron_python_test(self, *args):
125128
if not is_cli: return
126129
if args:
@@ -216,7 +219,7 @@ def run_test(name):
216219
# else:
217220
# ipython_executable = path_combine(sys.prefix, 'ipy.exe')
218221
# cpython_executable = sys.executable
219-
222+
220223
# #team_dir = path_combine(ip_root, r'Team')
221224
# #team_profile = path_combine(team_dir, r'settings.py')
222225
# #

Tests/test_missing.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -230,7 +230,7 @@ def TestCalls(t):
230230
r = getattr(t, n)()
231231
if trace: print(r)
232232

233-
@unittest.skipIf(is_netcoreapp, "TODO: figure out")
233+
@unittest.skipIf(is_netcoreapp, "TODO: figure out, make parallel-safe")
234234
@skipUnlessIronPython()
235235
class MissingTest(unittest.TestCase):
236236
def test_main(self):

0 commit comments

Comments
 (0)