Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow custom runner for CoreCLR test unix scripts #9007

Closed
nattress opened this Issue Jan 19, 2017 · 2 comments

Comments

Projects
None yet
4 participants
@nattress
Copy link
Member

nattress commented Jan 19, 2017

Each CoreCLR test has a Windows test.cmd and Unix test.sh script that runs the test. The Windows scripts allow a custom test runner so that CoreRun can be switched out (ie, with CoreRT). The Unix scripts need the same feature.

On Windows:

IF NOT "%CLRCustomTestLauncher%"=="" (
  set LAUNCHER=call %CLRCustomTestLauncher% %~dp0
) ELSE (
  set LAUNCHER=%_DebuggerFullPath% "%CORE_ROOT%\corerun.exe"
)
      
ECHO %LAUNCHER% class01.exe %CLRTestExecutionArguments%

What Unix currently has:

$_DebuggerFullPath "$CORE_ROOT/corerun" class01.exe $CLRTestExecutionArguments 

@nattress nattress added this to the Future milestone Jan 19, 2017

@gkhanna79

This comment has been minimized.

Copy link
Member

gkhanna79 commented Jan 29, 2017

@ramarag

This comment has been minimized.

Copy link
Member

ramarag commented Jan 29, 2017

The line that needs to be changed is

$(_CLRTestRunFile) $(TargetAssemblyName) $CLRTestExecutionArguments

For reference to what is done for windows look at :

IF NOT "%CLRCustomTestLauncher%"=="" (
set LAUNCHER=call %CLRCustomTestLauncher% %~dp0
) ELSE (
set LAUNCHER=%_DebuggerFullPath% $(_CLRTestRunFile)
)
]]></BatchCLRTestLaunchCmds>
<BatchCLRTestLaunchCmds Condition=" '$(IlasmRoundTrip)'=='true' "><![CDATA[
$(BatchCLRTestLaunchCmds)
ECHO %LAUNCHER% $(TargetAssemblyName) %CLRTestExecutionArguments% %Host_Args%
%LAUNCHER% $(TargetAssemblyName) %CLRTestExecutionArguments% %Host_Args%
IF NOT "!ERRORLEVEL!"=="%CLRTestExpectedExitCode%" (
ECHO END EXECUTION OF IL{D}ASM BINARY - FAILED !ERRORLEVEL! vs %CLRTestExpectedExitCode%
ECHO FAILED
Exit /b 1
)
]]></BatchCLRTestLaunchCmds>
<BatchCLRTestLaunchCmds Condition="'$(CLRTestKind)' == 'BuildAndRun'"><![CDATA[
$(BatchCLRTestLaunchCmds)
ECHO %LAUNCHER% $(InputAssemblyName) %CLRTestExecutionArguments%
%LAUNCHER% $(InputAssemblyName) %CLRTestExecutionArguments%

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.