-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
66 additions
and
49 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
88 changes: 47 additions & 41 deletions
88
test/Acornima.Tests.Test262/Acornima.Tests.Test262.csproj
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,52 +1,58 @@ | ||
<Project Sdk="Microsoft.NET.Sdk"> | ||
|
||
<PropertyGroup> | ||
<TargetFramework>net8.0</TargetFramework> | ||
<GenerateProgramFile>false</GenerateProgramFile> | ||
<GeneratedTestSuiteDir>Generated</GeneratedTestSuiteDir> | ||
</PropertyGroup> | ||
|
||
<PropertyGroup> | ||
<TargetFramework>net8.0</TargetFramework> | ||
<GenerateProgramFile>false</GenerateProgramFile> | ||
<GeneratedTestSuiteDir>Generated</GeneratedTestSuiteDir> | ||
</PropertyGroup> | ||
|
||
<PropertyGroup Label="Code Analysis"> | ||
<AnalysisLevel>latest-Recommended</AnalysisLevel> | ||
<NoWarn>$(NoWarn);CA1305</NoWarn> <!-- Specify IFormatProvider --> | ||
<NoWarn>$(NoWarn);CA1861</NoWarn> <!-- Avoid constant arrays as arguments --> | ||
</PropertyGroup> | ||
|
||
<ItemGroup> | ||
<PackageReference Include="GitHubActionsTestLogger" PrivateAssets="all" /> | ||
<PackageReference Include="Microsoft.NET.Test.Sdk" /> | ||
<PackageReference Include="NUnit" /> | ||
<PackageReference Include="NUnit3TestAdapter" /> | ||
<PackageReference Include="Spectre.Console" /> | ||
<PackageReference Include="Test262Harness" /> | ||
</ItemGroup> | ||
|
||
<ItemGroup> | ||
<ProjectReference Include="..\..\src\Acornima\Acornima.csproj" /> | ||
</ItemGroup> | ||
|
||
<ItemGroup> | ||
<Using Include="NUnit.Framework" /> | ||
</ItemGroup> | ||
|
||
<ItemGroup> | ||
<Content Include=".config\dotnet-tools.json" /> | ||
</ItemGroup> | ||
|
||
<!-- Based on the idea presented at https://mhut.ch/journal/2015/06/30/build-time-code-generation-in-msbuild --> | ||
<Target Name="GenerateTestSuite" DependsOnTargets="_GenerateTestSuite" BeforeTargets="BeforeBuild" Condition="!Exists($([System.IO.Path]::Combine($(MSBuildThisFileDirectory), $(GeneratedTestSuiteDir))))"> | ||
<ItemGroup> | ||
<PackageReference Include="GitHubActionsTestLogger" PrivateAssets="all" /> | ||
<PackageReference Include="Microsoft.NET.Test.Sdk" /> | ||
<PackageReference Include="NUnit" /> | ||
<PackageReference Include="NUnit3TestAdapter" /> | ||
<PackageReference Include="Spectre.Console" /> | ||
<PackageReference Include="Test262Harness" /> | ||
<Compile Include="$(GeneratedTestSuiteDir)\**\*.cs" /> | ||
</ItemGroup> | ||
</Target> | ||
|
||
<ItemGroup> | ||
<ProjectReference Include="..\..\src\Acornima\Acornima.csproj" /> | ||
</ItemGroup> | ||
<Target Name="_GenerateTestSuite"> | ||
<Exec Command="dotnet tool restore" /> | ||
<Exec Command="dotnet test262 generate" /> | ||
</Target> | ||
|
||
<ItemGroup> | ||
<Using Include="NUnit.Framework" /> | ||
</ItemGroup> | ||
<Target Name="DeleteTestSuite" DependsOnTargets="_DeleteTestSuite" AfterTargets="AfterClean" Condition="Exists($([System.IO.Path]::Combine($(MSBuildThisFileDirectory), $(GeneratedTestSuiteDir))))"> | ||
<RemoveDir Directories="$(GeneratedTestSuiteDir)" /> | ||
</Target> | ||
|
||
<Target Name="_DeleteTestSuite"> | ||
<ItemGroup> | ||
<Content Include=".config\dotnet-tools.json" /> | ||
<Compile Remove="$(GeneratedTestSuiteDir)\**\*.cs" /> | ||
</ItemGroup> | ||
|
||
<!-- Based on the idea presented at https://mhut.ch/journal/2015/06/30/build-time-code-generation-in-msbuild --> | ||
<Target Name="GenerateTestSuite" DependsOnTargets="_GenerateTestSuite" BeforeTargets="BeforeBuild" Condition="!Exists($([System.IO.Path]::Combine($(MSBuildThisFileDirectory), $(GeneratedTestSuiteDir))))"> | ||
<ItemGroup> | ||
<Compile Include="$(GeneratedTestSuiteDir)\**\*.cs" /> | ||
</ItemGroup> | ||
</Target> | ||
|
||
<Target Name="_GenerateTestSuite"> | ||
<Exec Command="dotnet tool restore" /> | ||
<Exec Command="dotnet test262 generate" /> | ||
</Target> | ||
|
||
<Target Name="DeleteTestSuite" DependsOnTargets="_DeleteTestSuite" AfterTargets="AfterClean" Condition="Exists($([System.IO.Path]::Combine($(MSBuildThisFileDirectory), $(GeneratedTestSuiteDir))))"> | ||
<RemoveDir Directories="$(GeneratedTestSuiteDir)" /> | ||
</Target> | ||
|
||
<Target Name="_DeleteTestSuite"> | ||
<ItemGroup> | ||
<Compile Remove="$(GeneratedTestSuiteDir)\**\*.cs" /> | ||
</ItemGroup> | ||
</Target> | ||
</Target> | ||
|
||
</Project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters