From: Michael R. Crusoe <crusoe@debian.org>
Subject: Ensure that python3 and not python (2) is used
Forwarded: https://github.com/DataBiosphere/toil/pull/3446
--- toil.orig/src/toil/test/utils/toilDebugTest.py
+++ toil/src/toil/test/utils/toilDebugTest.py
@@ -19,7 +19,7 @@
 
 from toil.test import ToilTest, slow, travis_test
 from toil.utils.toilDebugFile import recursiveGlob
-
+from toil.version import python
 logger = logging.getLogger(__name__)
 
 class ToilDebugFileTest(ToilTest):
@@ -27,7 +27,7 @@
 
     def setUp(self):
         """Initial set up of variables for the test."""
-        subprocess.check_call(['python', os.path.abspath('src/toil/test/utils/ABCWorkflowDebug/debugWorkflow.py')])
+        subprocess.check_call([python, os.path.abspath('src/toil/test/utils/ABCWorkflowDebug/debugWorkflow.py')])
         self.jobStoreDir = os.path.abspath('toilWorkflowRun')
         self.tempDir = self._createTempDir(purpose='tempDir')
         self.outputDir = os.path.abspath('testoutput')
@@ -54,7 +54,7 @@
 
         contents = ['A.txt', 'B.txt', 'C.txt', 'ABC.txt', 'mkFile.py']
 
-        subprocess.check_call(['python', os.path.abspath('src/toil/utils/toilDebugFile.py'), self.jobStoreDir, '--listFilesInJobStore=True'])
+        subprocess.check_call([python, os.path.abspath('src/toil/utils/toilDebugFile.py'), self.jobStoreDir, '--listFilesInJobStore=True'])
         jobstoreFileContents = os.path.abspath('jobstore_files.txt')
         files = []
         match = 0
@@ -95,7 +95,7 @@
         then delete them.
         """
         contents = ['A.txt', 'B.txt', 'C.txt', 'ABC.txt', 'mkFile.py']
-        cmd = ['python', os.path.abspath('src/toil/utils/toilDebugFile.py'),
+        cmd = [python, os.path.abspath('src/toil/utils/toilDebugFile.py'),
                self.jobStoreDir,
                '--fetch', '*A.txt', '*B.txt', '*C.txt', '*ABC.txt', '*mkFile.py',
                '--localFilePath=' + self.outputDir,
