$(OutputPath)$(MSBuildProjectName).cmd $(OutputPath)$([System.IO.Path]::GetFilenameWithoutExtension("$(CLRTestProjectToRun)")).exe $(OutputPath)$(MSBuildProjectName).$(OutputType.ToLower()) true debuggerFullPath Run testcases under debugger. true envScriptFullPath Run the specified script to set environment variables before running the test. true CoreRootFullPath Set CORE_ROOT to the specified value before running the test. $(MSBuildProjectName).reflect.xml nul REM Use hints for reflection roots, if provided in $(ReflectionRootsXml) IF EXIST $(ReflectionRootsXml) set ReflectionRoots=-x $(ReflectionRootsXml) REM Include all .exe files in this directory as entry points (some tests had multiple .exe file modules) FOR /F "delims=" %%E IN ('dir /b *.exe *.dll') DO SET Assemblies=!Assemblies! -a %%~nE REM Run dotnet-linker REM Run the Linker such that all assemblies except System.Private.Corlib.dll are linked REM Debug symbol generation needs some fixes, and is currently omitted. REM Once this is fixed, add -b true option. ECHO %ILLINK% -out %LinkBin% -d %CORE_ROOT% -c link -l none -t !Assemblies! !ReflectionRoots! %ILLINK% -out %LinkBin% -d %CORE_ROOT% -c link -l none -t !Assemblies! !ReflectionRoots! IF NOT "!ERRORLEVEL!"=="0" ( ECHO ILLINK FAILED !ERRORLEVEL! IF NOT defined KeepLinkedBinaries ( IF EXIST %LinkBin% rmdir /s /q %LinkBin% ) popd Exit /b 1 ) REM Copy CORECLR native binaries to %LinkBin%, so that we can run the test based on that directory copy %CORE_ROOT%\clrjit.dll %LinkBin% > nul 2> nul copy %CORE_ROOT%\coreclr.dll %LinkBin% > nul 2> nul copy %CORE_ROOT%\mscorrc.dll %LinkBin% > nul 2> nul copy %CORE_ROOT%\CoreRun.exe %LinkBin% > nul 2> nul REM Copy some files that may be arguments copy *.txt %LinkBin% > nul 2> nul set ExePath=%LinkBin%\$(InputAssemblyName) set CORE_ROOT=%~dp0%LinkBin% ) ]]> <_CLRTestRunFile Condition="'$(CLRTestIsHosted)'=='true'">"%CORE_ROOT%\corerun.exe" @(CLRTestBatchEnvironmentVariable -> '%(Identity)', '%0d%0a') <_RequiredProperties Include="_CLRTestRunFile"> $(_CLRTestRunFile) 'set cond=0 IF /I [%1] == [-%(Identity)] set cond=1 IF /I [%1] == [/%(Identity)] set cond=1 IF %cond% EQU 1 ( %(Command) shift IF /I [%(HasParam)] == [true] shift goto NextArg )',' ') if NOT "%1" == "" ( set CLRTestExecutionArguments=%* goto :ArgsDone ) goto ArgsDone :USAGE ECHO.Usage ECHO %0 $(_CLRTestParamList) ECHO. ECHO - OPTIONS - @(BatchCLRTestExecutionScriptArgument -> 'ECHO -%(Identity) %(ParamName) ECHO %(Description)', ' ') popd Exit /b 1 :ArgsDone $(BatchCLRTestArgPrep) ]]> <_CLRTestExecutionScriptText>