# HG changeset patch # User Gregory Szorc # Date 2022-02-20 20:29:47 # Node ID f547a5dee234dc06834a13af9974805384e1f03f # Parent 2ccd5e71bcd355ea20e7db377f903b698552682b tests: unconditionalize some imports Now that we require Python 3 we can simplify these imports. Differential Revision: https://phab.mercurial-scm.org/D12245 diff --git a/tests/run-tests.py b/tests/run-tests.py --- a/tests/run-tests.py +++ b/tests/run-tests.py @@ -57,8 +57,10 @@ import json import multiprocessing import os import platform +import queue import random import re +import shlex import shutil import signal import socket @@ -73,20 +75,7 @@ import uuid import xml.dom.minidom as minidom WINDOWS = os.name == r'nt' - -try: - import Queue as queue -except ImportError: - import queue - -try: - import shlex - - shellquote = shlex.quote -except (ImportError, AttributeError): - import pipes - - shellquote = pipes.quote +shellquote = shlex.quote processlock = threading.Lock()