<commit_before><?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">

  <!-- This is the target that copies the test assets to the test output -->
  <Import Project="$(MSBuildThisFileDirectory)publishtest.targets" />
  <UsingTask TaskName="GenerateTestExecutionScripts" AssemblyFile="$(BuildToolsTaskDir)Microsoft.DotNet.Build.Tasks.dll"/>
  <UsingTask TaskName="GetTargetMachineInfo" AssemblyFile="$(BuildToolsTaskDir)Microsoft.DotNet.Build.Tasks.dll"/>

    <!-- Which categories of tests to run by default -->
  <PropertyGroup>
    <TestDisabled>false</TestDisabled>
    <TestDisabled Condition="'$(IsTestProject)'!='true' Or '$(SkipTests)'=='true' Or '$(RunTestsForProject)'=='false'">true</TestDisabled>
    <TestsSuccessfulSemaphore>tests.passed</TestsSuccessfulSemaphore>
  </PropertyGroup>

  <!-- In case that TestPath is not yet set, default it here -->
  <PropertyGroup>
    <TestPath Condition="'$(TestPath)'==''">$(OutDir)</TestPath>
  </PropertyGroup>

  <ItemGroup>
    <!-- Split semicolon separated lists -->
    <WithCategoriesItems Include="$(WithCategories)" />
    <WithoutCategoriesItems Include="$(WithoutCategories)" />
    <DefaultNoCategories Include="$(DefaultNoCategories)" />
    <UnsupportedPlatformsItems Include="$(UnsupportedPlatforms)"/>
  </ItemGroup>

  <PropertyGroup>
    <XunitRuntimeConfig>$(ToolsDir)\xunit.console.netcore.runtimeconfig.json</XunitRuntimeConfig>
    <TestRuntimeEnvVar Condition="'$(OS)' == 'Windows_NT'">%RUNTIME_PATH%\</TestRuntimeEnvVar>
    <TestRuntimeEnvVar Condition="'$(OS)' != 'Windows_NT'">$RUNTIME_PATH/</TestRuntimeEnvVar>
    <TestHostExecutablePath Condition="'$(OS)'=='Windows_NT' AND '$(TestHostExecutablePath)' == ''">$(TestRuntimeEnvVar)dotnet.exe</TestHostExecutablePath>
    <TestHostExecutablePath Condition="'$(OS)'!='Windows_NT' AND '$(TestHostExecutablePath)' == ''">$(TestRuntimeEnvVar)dotnet</TestHostExecutablePath>

    <ExecutionDirEnvVar Condition="'$(OS)' == 'Windows_NT'">%EXECUTION_DIR%\</ExecutionDirEnvVar>
    <ExecutionDirEnvVar Condition="'$(OS)' != 'Windows_NT'">$EXECUTION_DIR/</ExecutionDirEnvVar>
    <XunitExecutable Condition="'$(XunitExecutable)' == ''">$(ExecutionDirEnvVar)xunit.console.netcore.exe</XunitExecutable>

    <DebugEngines>{2E36F1D4-B23C-435D-AB41-18E608940038}</DebugEngines>
  </PropertyGroup>

  <!-- General xunit options -->
  <PropertyGroup>
    <XunitResultsFileName>testResults.xml</XunitResultsFileName>

    <XunitOptions Condition="'$(TestWithCore)' != 'true'">$(XunitOptions) -noshadow </XunitOptions>
    <XunitOptions>$(XunitOptions) -xml $(XunitResultsFileName)</XunitOptions>

    <XunitOptions Condition="'$(Performance)'!='true'">$(XunitOptions) -notrait Benchmark=true</XunitOptions>

    <XunitOptions Condition="'$(UseDotNetNativeToolchain)'=='true'">$(XunitOptions) -redirectoutput</XunitOptions>

    <XunitOptions Condition="'$(TestTFM)'!=''">$(XunitOptions) -notrait category=non$(TestTFM)tests</XunitOptions>
    <XunitOptions Condition="'$(XunitMaxThreads)'!=''">$(XunitOptions) -maxthreads $(XunitMaxThreads)</XunitOptions>
    <XunitTestAssembly Condition="'$(XunitTestAssembly)' == ''">$(TargetFileName)</XunitTestAssembly>
    <XunitArguments>$(XunitTestAssembly) $(XunitOptions)</XunitArguments>

    <TestProgram Condition="'$(TestHostExecutablePath)'!=''">$(TestHostExecutablePath)</TestProgram>
    <TestArguments Condition="'$(TestHostExecutablePath)'!=''">$(XunitExecutable) $(XunitArguments)</TestArguments>

    <TestProgram Condition="'$(TestHostExecutablePath)'==''">$(XunitExecutable)</TestProgram>
    <TestArguments Condition="'$(TestHostExecutablePath)'==''">$(XunitArguments)</TestArguments>

    <TestCommandLine Condition="'$(Performance)'!='true'">$(TestProgram) $(TestArguments) {XunitTraitOptions}</TestCommandLine>
  </PropertyGroup>

  <!-- The Code Coverage targets will override TestHost and TestCommandLine if coverage is enabled -->
  <Import Project="$(MSBuildThisFileDirectory)CodeCoverage.targets" />

  <!-- In VS (2015 Preview or later currently required): Debug to run unit tests on CoreCLR. -->
  <PropertyGroup Condition="'$(IsTestProject)'=='true'">
    <StartWorkingDirectory Condition="'$(StartWorkingDirectory)'==''">$(TestPath)</StartWorkingDirectory>
    <StartAction Condition="'$(StartAction)'==''">Program</StartAction>
    <StartProgram Condition="'$(StartProgram)'==''">$(TestProgram)</StartProgram>
    <StartArguments Condition="'$(StartArguments)'==''">$(TestArguments) -wait -parallel none</StartArguments>
  </PropertyGroup>

  <Target Name="DiscoverTestInputs" DependsOnTargets="ResolveReferences;GetCopyToOutputDirectoryItems">
    <ItemGroup>
      <RunTestsForProjectInputs Include="@(ReferenceCopyLocalPaths)" />
      <RunTestsForProjectInputs Include="@(Content)" />
      <RunTestsForProjectInputs Include="@(IntermediateAssembly)" />
      <RunTestsForProjectInputs Include="@(_DebugSymbolsIntermediatePath)" />
      <RunTestsForProjectInputs Include="@(AllItemsFullPathWithTargetPath)" />
    </ItemGroup>
    <ItemGroup>
      <SupplementalTestData Include="$(XunitRuntimeConfig)" />
      <SupplementalTestData Include="$(RuntimePath)xunit.console.netcore.exe" />
    </ItemGroup>
  </Target>

  <!-- Generate the script to run the tests.  The script performs two high-level steps:
       1.  Copies the common test runtime dependencies calculated in DiscoverTestDependencies to the test<commit_msg>Fix F5 to run tests in VS (#15297)<commit_after><?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">

  <!-- This is the target that copies the test assets to the test output -->
  <Import Project="$(MSBuildThisFileDirectory)publishtest.targets" />
  <UsingTask TaskName="GenerateTestExecutionScripts" AssemblyFile="$(BuildToolsTaskDir)Microsoft.DotNet.Build.Tasks.dll"/>
  <UsingTask TaskName="GetTargetMachineInfo" AssemblyFile="$(BuildToolsTaskDir)Microsoft.DotNet.Build.Tasks.dll"/>

    <!-- Which categories of tests to run by default -->
  <PropertyGroup>
    <TestDisabled>false</TestDisabled>
    <TestDisabled Condition="'$(IsTestProject)'!='true' Or '$(SkipTests)'=='true' Or '$(RunTestsForProject)'=='false'">true</TestDisabled>
    <TestsSuccessfulSemaphore>tests.passed</TestsSuccessfulSemaphore>
  </PropertyGroup>

  <!-- In case that TestPath is not yet set, default it here -->
  <PropertyGroup>
    <TestPath Condition="'$(TestPath)'==''">$(OutDir)</TestPath>
  </PropertyGroup>

  <ItemGroup>
    <!-- Split semicolon separated lists -->
    <WithCategoriesItems Include="$(WithCategories)" />
    <WithoutCategoriesItems Include="$(WithoutCategories)" />
    <DefaultNoCategories Include="$(DefaultNoCategories)" />
    <UnsupportedPlatformsItems Include="$(UnsupportedPlatforms)"/>
  </ItemGroup>

  <PropertyGroup>
    <XunitRuntimeConfig>$(ToolsDir)\xunit.console.netcore.runtimeconfig.json</XunitRuntimeConfig>
    <TestRuntimeEnvVar Condition="'$(OS)' == 'Windows_NT'">%RUNTIME_PATH%\</TestRuntimeEnvVar>
    <TestRuntimeEnvVar Condition="'$(OS)' != 'Windows_NT'">$RUNTIME_PATH/</TestRuntimeEnvVar>
    <TestHostExecutablePath Condition="'$(OS)'=='Windows_NT' AND '$(TestHostExecutablePath)' == ''">$(TestRuntimeEnvVar)dotnet.exe</TestHostExecutablePath>
    <TestHostExecutablePath Condition="'$(OS)'!='Windows_NT' AND '$(TestHostExecutablePath)' == ''">$(TestRuntimeEnvVar)dotnet</TestHostExecutablePath>

    <XunitExecutable Condition="'$(XunitExecutable)' == ''">xunit.console.netcore.exe</XunitExecutable>

    <DebugEngines>{2E36F1D4-B23C-435D-AB41-18E608940038}</DebugEngines>
  </PropertyGroup>

  <!-- General xunit options -->
  <PropertyGroup>
    <XunitResultsFileName>testResults.xml</XunitResultsFileName>

    <XunitOptions Condition="'$(TestWithCore)' != 'true'">$(XunitOptions) -noshadow </XunitOptions>
    <XunitOptions>$(XunitOptions) -xml $(XunitResultsFileName)</XunitOptions>

    <XunitOptions Condition="'$(Performance)'!='true'">$(XunitOptions) -notrait Benchmark=true</XunitOptions>

    <XunitOptions Condition="'$(UseDotNetNativeToolchain)'=='true'">$(XunitOptions) -redirectoutput</XunitOptions>

    <XunitOptions Condition="'$(TestTFM)'!=''">$(XunitOptions) -notrait category=non$(TestTFM)tests</XunitOptions>
    <XunitOptions Condition="'$(XunitMaxThreads)'!=''">$(XunitOptions) -maxthreads $(XunitMaxThreads)</XunitOptions>
    <XunitTestAssembly Condition="'$(XunitTestAssembly)' == ''">$(TargetFileName)</XunitTestAssembly>
    <XunitArguments>$(XunitTestAssembly) $(XunitOptions)</XunitArguments>

    <TestProgram Condition="'$(TestHostExecutablePath)'!=''">$(TestHostExecutablePath)</TestProgram>
    <TestArguments Condition="'$(TestHostExecutablePath)'!=''">$(XunitExecutable) $(XunitArguments)</TestArguments>

    <TestProgram Condition="'$(TestHostExecutablePath)'==''">$(XunitExecutable)</TestProgram>
    <TestArguments Condition="'$(TestHostExecutablePath)'==''">$(XunitArguments)</TestArguments>

    <TestCommandLine Condition="'$(Performance)'!='true'">$(TestProgram) $(TestArguments) {XunitTraitOptions}</TestCommandLine>
  </PropertyGroup>

  <!-- The Code Coverage targets will override TestHost and TestCommandLine if coverage is enabled -->
  <Import Project="$(MSBuildThisFileDirectory)CodeCoverage.targets" />

  <!-- In VS (2015 Preview or later currently required): Debug to run unit tests on CoreCLR. -->
  <PropertyGroup Condition="'$(IsTestProject)'=='true'">
    <StartWorkingDirectory Condition="'$(StartWorkingDirectory)'==''">$(TestPath)</StartWorkingDirectory>
    <StartAction Condition="'$(StartAction)'==''">Program</StartAction>
    <StartProgram Condition="'$(StartProgram)'==''">$(TestSharedFxDir)\dotnet.exe</StartProgram>
    <StartArguments Condition="'$(StartArguments)'==''">$(TestArguments) -wait -parallel none</StartArguments>
  </PropertyGroup>

  <Target Name="DiscoverTestInputs" DependsOnTargets="ResolveReferences;GetCopyToOutputDirectoryItems">
    <ItemGroup>
      <RunTestsForProjectInputs Include="@(ReferenceCopyLocalPaths)" />
      <RunTestsForProjectInputs Include="@(Content)" />
      <RunTestsForProjectInputs Include="@(IntermediateAssembly)" />
      <RunTestsForProjectInputs Include="@(_DebugSymbolsIntermediatePath)" />
      <RunTestsForProjectInputs Include="@(AllItemsFullPathWithTargetPath)" />
    </ItemGroup>
    <ItemGroup>
      <SupplementalTestData Include="$(XunitRuntimeConfig)" />
      <SupplementalTestData Include="$(RuntimePath)xunit.console.netcore.exe" />
    </ItemGroup>
  </Target>

  <!-- Generate the script to run the tests.  The script performs two high-level steps:
       1.  Copies the common test runtime dependencies calculated in DiscoverTestDependencies to the test
{'fraction_non_alphanumeric': 0.16540029651593774, 'fraction_numerical': 0.00759822090437361, 'mean_word_length': 6.787157287157287, 'pattern_counts': {'":': 0, '<': 209, '<?xml version=': 2, '>': 207, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 8}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1655641', 'n_tokens_mistral': 3291, 'n_tokens_neox': 2936, 'n_words': 484}