summaryrefslogtreecommitdiffstats
path: root/Lib/test/libregrtest/main.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/test/libregrtest/main.py')
-rw-r--r--Lib/test/libregrtest/main.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/Lib/test/libregrtest/main.py b/Lib/test/libregrtest/main.py
index 8d44caf..32ac440 100644
--- a/Lib/test/libregrtest/main.py
+++ b/Lib/test/libregrtest/main.py
@@ -1,5 +1,6 @@
import datetime
import faulthandler
+import json
import locale
import os
import platform
@@ -565,6 +566,9 @@ class Regrtest:
if self.ns.tempdir:
TEMPDIR = self.ns.tempdir
+ elif self.ns.worker_args:
+ ns_dict, _ = json.loads(self.ns.worker_args)
+ TEMPDIR = ns_dict.get("tempdir") or TEMPDIR
os.makedirs(TEMPDIR, exist_ok=True)