@@ -245,16 +245,20 @@ def run(self):
245
245
Runs the specified scenario
246
246
'''
247
247
self .parseargs ()
248
+
249
+ python_command = pythoncommand ().split (' ' )
250
+ python_exe = python_command [0 ]
251
+ python_args = " " .join (python_command [1 :])
248
252
if self .testtype == const .INNERLOOP :
249
253
startup = StartupWrapper ()
250
254
self .traits .add_traits (scenarioname = self .scenarioname ,
251
255
scenariotypename = const .SCENARIO_NAMES [const .INNERLOOP ],
252
256
apptorun = 'dotnet' , appargs = 'run --project %s' % appfolder (self .traits .exename , self .traits .projext ),
253
- innerloopcommand = pythoncommand () ,
254
- iterationsetup = pythoncommand () ,
255
- setupargs = '%s %s setup_build' % ('-3' if iswin () else '' , const .ITERATION_SETUP_FILE ),
256
- iterationcleanup = pythoncommand () ,
257
- cleanupargs = '%s %s cleanup' % ('-3' if iswin () else '' , const .ITERATION_SETUP_FILE ),
257
+ innerloopcommand = python_exe ,
258
+ iterationsetup = python_exe ,
259
+ setupargs = '%s %s setup_build' % (python_args , const .ITERATION_SETUP_FILE ),
260
+ iterationcleanup = python_exe ,
261
+ cleanupargs = '%s %s cleanup' % (python_args , const .ITERATION_SETUP_FILE ),
258
262
affinity = self .affinity )
259
263
startup .runtests (self .traits )
260
264
@@ -263,11 +267,11 @@ def run(self):
263
267
self .traits .add_traits (scenarioname = self .scenarioname ,
264
268
scenariotypename = const .SCENARIO_NAMES [const .INNERLOOPMSBUILD ],
265
269
apptorun = 'dotnet' , appargs = 'run --project %s' % appfolder (self .traits .exename , self .traits .projext ),
266
- innerloopcommand = pythoncommand () ,
267
- iterationsetup = pythoncommand () ,
268
- setupargs = '%s %s setup_build' % ('-3' if iswin () else '' , const .ITERATION_SETUP_FILE ),
269
- iterationcleanup = pythoncommand () ,
270
- cleanupargs = '%s %s cleanup' % ('-3' if iswin () else '' , const .ITERATION_SETUP_FILE ),
270
+ innerloopcommand = python_exe ,
271
+ iterationsetup = python_exe ,
272
+ setupargs = '%s %s setup_build' % (python_args , const .ITERATION_SETUP_FILE ),
273
+ iterationcleanup = python_exe ,
274
+ cleanupargs = '%s %s cleanup' % (python_args , const .ITERATION_SETUP_FILE ),
271
275
affinity = self .affinity )
272
276
startup .runtests (self .traits )
273
277
@@ -276,11 +280,11 @@ def run(self):
276
280
self .traits .add_traits (scenarioname = self .scenarioname ,
277
281
scenariotypename = const .SCENARIO_NAMES [const .DOTNETWATCH ],
278
282
apptorun = 'dotnet' , appargs = 'watch -v' ,
279
- innerloopcommand = pythoncommand () ,
280
- iterationsetup = pythoncommand () ,
281
- setupargs = '%s %s setup_build' % ('-3' if iswin () else '' , const .ITERATION_SETUP_FILE ),
282
- iterationcleanup = pythoncommand () ,
283
- cleanupargs = '%s %s cleanup' % ('-3' if iswin () else '' , const .ITERATION_SETUP_FILE ),
283
+ innerloopcommand = python_exe ,
284
+ iterationsetup = python_exe ,
285
+ setupargs = '%s %s setup_build' % (python_args , const .ITERATION_SETUP_FILE ),
286
+ iterationcleanup = python_exe ,
287
+ cleanupargs = '%s %s cleanup' % (python_args , const .ITERATION_SETUP_FILE ),
284
288
affinity = self .affinity )
285
289
self .traits .add_traits (workingdir = const .APPDIR )
286
290
startup .runtests (self .traits )
@@ -312,10 +316,10 @@ def run(self):
312
316
scenariotypename = '%s_%s' % (const .SCENARIO_NAMES [const .SDK ], const .CLEAN_BUILD ),
313
317
apptorun = const .DOTNET ,
314
318
appargs = 'build' ,
315
- iterationsetup = pythoncommand () ,
316
- setupargs = '%s %s setup_build' % ('-3' if iswin () else '' , const .ITERATION_SETUP_FILE ),
317
- iterationcleanup = pythoncommand () ,
318
- cleanupargs = '%s %s cleanup' % ('-3' if iswin () else '' , const .ITERATION_SETUP_FILE ),
319
+ iterationsetup = python_exe ,
320
+ setupargs = '%s %s setup_build' % (python_args , const .ITERATION_SETUP_FILE ),
321
+ iterationcleanup = python_exe ,
322
+ cleanupargs = '%s %s cleanup' % (python_args , const .ITERATION_SETUP_FILE ),
319
323
workingdir = const .APPDIR ,
320
324
environmentvariables = envlistcleanbuild ,
321
325
)
@@ -344,10 +348,10 @@ def run(self):
344
348
apptorun = const .DOTNET ,
345
349
scenarioname = self .scenarioname ,
346
350
scenariotypename = '%s_%s' % (const .SCENARIO_NAMES [const .SDK ], const .NEW_CONSOLE ),
347
- iterationsetup = pythoncommand () ,
348
- setupargs = '%s %s setup_new' % ('-3' if iswin () else '' , const .ITERATION_SETUP_FILE ),
349
- iterationcleanup = pythoncommand () ,
350
- cleanupargs = '%s %s cleanup' % ('-3' if iswin () else '' , const .ITERATION_SETUP_FILE ),
351
+ iterationsetup = python_exe ,
352
+ setupargs = '%s %s setup_new' % (python_args , const .ITERATION_SETUP_FILE ),
353
+ iterationcleanup = python_exe ,
354
+ cleanupargs = '%s %s cleanup' % (python_args , const .ITERATION_SETUP_FILE ),
351
355
workingdir = const .APPDIR
352
356
)
353
357
self .traits .add_traits (overwrite = True , startupmetric = const .STARTUP_PROCESSTIME )
0 commit comments