Skip to content

Adds Test target - #9193

Merged
JanKrivanek merged 8 commits into
dotnet:mainfrom
novacole:addtesttarget
Nov 28, 2023
Merged

JanKrivanek merged 8 commits into
dotnet:mainfrom
novacole:addtesttarget

Conversation

@novacole

@novacole novacole commented Aug 30, 2023

Copy link
Copy Markdown
Contributor

Context

At the moment we can run tests with dotnet /test, but the same is not true for MSBuild directly. In order to allow for such functionality, a new target is needed.

Since it is possible that there exist targets with the name "Test" in the wild, this target is behind a condition, to avoid breaking users who have not opted-in.

usage:
msbuild /t:Test /p:UseMSBuildTestInfrastructure=true

Changes Made

@JanKrivanek JanKrivanek left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks ok.

Before merging it just needs explicit approval from 1ES and sdk team about the overal msbuild /test idea and its implementation.

@MarcoRossignoli

Copy link
Copy Markdown
Member

Is there some ETA for this one?

Update target name, as requested by Test team
Comment thread src/Tasks/Microsoft.Common.CurrentVersion.targets Outdated
@novacole novacole changed the title Adds MSBuildRunTests target Adds Test target Nov 15, 2023
Comment thread src/Tasks/Microsoft.Common.Test.targets Outdated
Comment thread src/Tasks/Microsoft.Common.CurrentVersion.targets Outdated
Comment thread src/Tasks/Microsoft.Common.CurrentVersion.targets Outdated

@MarcoRossignoli MarcoRossignoli left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

some nit LGTM

Comment thread src/Tasks/Microsoft.Common.CurrentVersion.targets Outdated
Comment thread src/Tasks/Microsoft.Common.CurrentVersion.targets Outdated
@JanKrivanek

Copy link
Copy Markdown
Member

Closing to wake-up stuck auto-merge

@JanKrivanek JanKrivanek reopened this Nov 27, 2023
@JanKrivanek
JanKrivanek merged commit b9d3539 into dotnet:main Nov 28, 2023
rainersigwald added a commit to rainersigwald/msbuild that referenced this pull request Dec 15, 2023
This was added in dotnet#9193 but not usable in VS.
rainersigwald added a commit that referenced this pull request Dec 18, 2023
This was added in #9193 but not usable in VS.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants