Skip to content

Commit

Permalink
Revert source build (#4637) (#4664)
Browse files Browse the repository at this point in the history
Co-authored-by: Jakub Jareš <[email protected]>
  • Loading branch information
Evangelink and nohwnd authored Jan 15, 2025
1 parent 4cd8080 commit 983fbaa
Show file tree
Hide file tree
Showing 7 changed files with 36 additions and 90 deletions.
1 change: 0 additions & 1 deletion azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@ stages:
enablePublishBuildAssets: true
enablePublishUsingPipelines: true
enableTelemetry: true
enableSourceBuild: true
jobs:
- job: Windows
timeoutInMinutes: 90
Expand Down
3 changes: 1 addition & 2 deletions eng/Analyzers.props
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,7 @@
<EnforceCodeStyleInBuild>true</EnforceCodeStyleInBuild>
</PropertyGroup>

<!-- Source build requires that everything needed for build is source-buildable, so we don't use analyzers for source build. -->
<ItemGroup Condition=" '$(DotNetBuildSourceOnly)' != 'true' ">
<ItemGroup>
<PackageReference Include="Microsoft.CodeAnalysis.PublicApiAnalyzers" PrivateAssets="all" Condition="'$(IsSourceProject)' == 'true'" />
<PackageReference Include="Microsoft.CodeAnalysis.BannedApiAnalyzers" PrivateAssets="all" />

Expand Down
69 changes: 30 additions & 39 deletions eng/Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -4,47 +4,38 @@
<ProductsToBuild Condition=" '$(ProductsToBuild)' == '' ">all</ProductsToBuild>
</PropertyGroup>

<Choose>
<When Condition=" '$(DotNetBuildSourceOnly)' == 'true' ">
<!-- When building for source build we only want to build the platform, this is the only component shared to dotnet/sdk. -->
<ItemGroup>
<ProjectToBuild Include="$(RepoRoot)src/Platform/Microsoft.Testing.Platform/Microsoft.Testing.Platform.csproj" />
</ItemGroup>
</When>
<Otherwise>
<!-- When building all products on windows OS -->
<ItemGroup Condition=" '$(ProductsToBuild)' == 'all' AND '$(OS)' == 'Windows_NT' ">
<ProjectToBuild Include="$(RepoRoot)TestFx.sln" />
</ItemGroup>
<!-- When building all products on windows OS -->
<ItemGroup Condition=" '$(ProductsToBuild)' == 'all' AND '$(OS)' == 'Windows_NT' ">
<ProjectToBuild Include="$(RepoRoot)TestFx.sln" />
</ItemGroup>

<!-- When building all products on non-windows OSes -->
<ItemGroup Condition=" '$(ProductsToBuild)' == 'all' AND '$(OS)' != 'Windows_NT' ">
<ProjectToBuild Include="$(RepoRoot)src/**/*.csproj" />
<ProjectToBuild Include="$(RepoRoot)test/UnitTests/MSTest.Analyzers.UnitTests/MSTest.Analyzers.UnitTests.csproj" />
<ProjectToBuild Include="$(RepoRoot)test/UnitTests/Microsoft.Testing.*/Microsoft.Testing.*.csproj" />
<ProjectToBuild Include="$(RepoRoot)test/IntegrationTests/Microsoft.Testing.Platform.Acceptance.IntegrationTests/Microsoft.Testing.Platform.Acceptance.IntegrationTests.csproj" />
<ProjectToBuild Include="$(RepoRoot)test/IntegrationTests/MSTest.Acceptance.IntegrationTests/MSTest.Acceptance.IntegrationTests.csproj" />
</ItemGroup>
<!-- When building all products on non-windows OSes -->
<ItemGroup Condition=" '$(ProductsToBuild)' == 'all' AND '$(OS)' != 'Windows_NT' ">
<ProjectToBuild Include="$(RepoRoot)src/**/*.csproj" />
<ProjectToBuild Include="$(RepoRoot)test/UnitTests/MSTest.Analyzers.UnitTests/MSTest.Analyzers.UnitTests.csproj" />
<ProjectToBuild Include="$(RepoRoot)test/UnitTests/Microsoft.Testing.*/Microsoft.Testing.*.csproj" />
<ProjectToBuild Include="$(RepoRoot)test/IntegrationTests/Microsoft.Testing.Platform.Acceptance.IntegrationTests/Microsoft.Testing.Platform.Acceptance.IntegrationTests.csproj" />
<ProjectToBuild Include="$(RepoRoot)test/IntegrationTests/MSTest.Acceptance.IntegrationTests/MSTest.Acceptance.IntegrationTests.csproj" />
</ItemGroup>

<!-- When building MSTest only on windows OS -->
<ItemGroup Condition=" '$(ProductsToBuild)' == 'mstest' AND '$(OS)' == 'Windows_NT' ">
<ProjectToBuild Include="$(RepoRoot)MSTest.slnf" />
</ItemGroup>
<!-- When building MSTest only on windows OS -->
<ItemGroup Condition=" '$(ProductsToBuild)' == 'mstest' AND '$(OS)' == 'Windows_NT' ">
<ProjectToBuild Include="$(RepoRoot)MSTest.slnf" />
</ItemGroup>

<!-- When building MSTest only on non-windows OSes -->
<ItemGroup Condition=" '$(ProductsToBuild)' == 'mstest' AND '$(OS)' != 'Windows_NT' ">
<ProjectToBuild Include="$(RepoRoot)src/Adapter/**/*.csproj" />
<ProjectToBuild Include="$(RepoRoot)src/Analyzers/**/*.csproj" />
<ProjectToBuild Include="$(RepoRoot)src/Package/**/*.csproj" />
<ProjectToBuild Include="$(RepoRoot)src/TestFramework/**/*.csproj" />
<ProjectToBuild Include="$(RepoRoot)test/UnitTests/MSTest.Analyzers.UnitTests/MSTest.Analyzers.UnitTests.csproj" />
<ProjectToBuild Include="$(RepoRoot)test/IntegrationTests/MSTest.Acceptance.IntegrationTests/MSTest.Acceptance.IntegrationTests.csproj" />
</ItemGroup>
<!-- When building MSTest only on non-windows OSes -->
<ItemGroup Condition=" '$(ProductsToBuild)' == 'mstest' AND '$(OS)' != 'Windows_NT' ">
<ProjectToBuild Include="$(RepoRoot)src/Adapter/**/*.csproj" />
<ProjectToBuild Include="$(RepoRoot)src/Analyzers/**/*.csproj" />
<ProjectToBuild Include="$(RepoRoot)src/Package/**/*.csproj" />
<ProjectToBuild Include="$(RepoRoot)src/TestFramework/**/*.csproj" />
<ProjectToBuild Include="$(RepoRoot)test/UnitTests/MSTest.Analyzers.UnitTests/MSTest.Analyzers.UnitTests.csproj" />
<ProjectToBuild Include="$(RepoRoot)test/IntegrationTests/MSTest.Acceptance.IntegrationTests/MSTest.Acceptance.IntegrationTests.csproj" />
</ItemGroup>

<!-- When building Microsoft.Testing.Platform only -->
<ItemGroup Condition=" '$(ProductsToBuild)' == 'testing-platform' ">
<ProjectToBuild Include="$(RepoRoot)Microsoft.Testing.Platform.slnf" />
</ItemGroup>

<!-- When building Microsoft.Testing.Platform only -->
<ItemGroup Condition=" '$(ProductsToBuild)' == 'testing-platform' ">
<ProjectToBuild Include="$(RepoRoot)Microsoft.Testing.Platform.slnf" />
</ItemGroup>
</Otherwise>
</Choose>
</Project>
10 changes: 0 additions & 10 deletions eng/DotNetBuild.props

This file was deleted.

9 changes: 0 additions & 9 deletions eng/SourceBuildPrebuiltBaseline.xml

This file was deleted.

24 changes: 0 additions & 24 deletions eng/Version.Details.xml
Original file line number Diff line number Diff line change
Expand Up @@ -25,29 +25,5 @@
<Uri>https://github.com/microsoft/testanywhere</Uri>
<Sha>2346f405dcb5150b567970995dc978feb26b2db0</Sha>
</Dependency>
<!-- Intermediate is necessary for source build. -->
<Dependency Name="Microsoft.SourceBuild.Intermediate.diagnostics" Version="9.0.0-preview.24566.1">
<Uri>https://github.com/dotnet/diagnostics</Uri>
<Sha>8c505ca6921b5f7e9b8acc234cc8f15035537ee4</Sha>
<SourceBuild RepoName="diagnostics" ManagedOnly="true" />
</Dependency>
<!-- Intermediate is necessary for source build. -->
<Dependency Name="Microsoft.SourceBuild.Intermediate.source-build-externals" Version="9.0.0-alpha.1.24175.1">
<Uri>https://github.com/dotnet/source-build-externals</Uri>
<Sha>4df883d781a4290873b3b968afc0ff0df7132507</Sha>
<SourceBuild RepoName="source-build-externals" ManagedOnly="true" />
</Dependency>
<!-- Intermediate is necessary for source build. -->
<Dependency Name="Microsoft.SourceBuild.Intermediate.source-build-reference-packages" Version="10.0.561001">
<Uri>https://github.com/dotnet/source-build-reference-packages</Uri>
<Sha>94798e07efab2663f2d1a71862780bc365d2e3ab</Sha>
<SourceBuild RepoName="source-build-reference-packages" ManagedOnly="true" />
</Dependency>
<!-- Intermediate is necessary for source build. -->
<Dependency Name="Microsoft.SourceBuild.Intermediate.arcade" Version="10.0.0-beta.24604.4">
<Uri>https://github.com/dotnet/arcade</Uri>
<Sha>45d845e04c05fbe5da9838c454bbc3af1df6be81</Sha>
<SourceBuild RepoName="arcade" ManagedOnly="true" />
</Dependency>
</ToolsetDependencies>
</Dependencies>
10 changes: 5 additions & 5 deletions eng/verify-nupkgs.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,11 @@ function Unzip {
function Confirm-NugetPackages {
Write-Verbose "Starting Confirm-NugetPackages."
$expectedNumOfFiles = @{
"MSTest.Sdk" = 15;
"MSTest.TestFramework" = 148;
"MSTest.TestAdapter" = 75;
"MSTest" = 6;
"MSTest.Analyzers" = 50;
"MSTest.Sdk" = 15
"MSTest.TestFramework" = 148
"MSTest.TestAdapter" = 75
"MSTest" = 6
"MSTest.Analyzers" = 50
}

$packageDirectory = Resolve-Path "$PSScriptRoot/../artifacts/packages/$configuration"
Expand Down

0 comments on commit 983fbaa

Please sign in to comment.