|
1 | 1 | <?xml version="1.0" encoding="utf-8"?> |
2 | 2 | <!-- |
3 | 3 | Copyright (c) Microsoft Corporation. All rights reserved. |
4 | | - |
| 4 | +
|
5 | 5 | Licensed under the MIT license. |
6 | 6 | --> |
7 | 7 | <Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> |
|
17 | 17 | <OutputPath Condition=" '$(Configuration)' != '' And '$(Platform)' == '' ">bin\$(Configuration)\</OutputPath> |
18 | 18 | <OutputPath Condition=" '$(Configuration)' != '' And '$(Platform)' != '' ">bin\$(Configuration)\$(Platform)\</OutputPath> |
19 | 19 | </PropertyGroup> |
20 | | - |
| 20 | + |
21 | 21 | <Import Project="$(MSBuildToolsPath)\Microsoft.Common.targets" Condition=" Exists('$(MSBuildToolsPath)\Microsoft.Common.targets') " /> |
22 | 22 |
|
23 | 23 | <PropertyGroup> |
|
47 | 47 | Build |
48 | 48 | </TestDependsOn> |
49 | 49 |
|
| 50 | + <VSTestDependsOn> |
| 51 | + Build |
| 52 | + </VSTestDependsOn> |
| 53 | + |
50 | 54 | <CleanDependsOn> |
51 | 55 | BeforeClean; |
52 | 56 | UnmanagedUnregistration; |
|
59 | 63 | <PackDependsOn> |
60 | 64 | ResolveReferences; |
61 | 65 | </PackDependsOn> |
| 66 | + |
| 67 | + <PublishDependsOn> |
| 68 | + Build; |
| 69 | + </PublishDependsOn> |
62 | 70 | </PropertyGroup> |
63 | 71 |
|
64 | 72 | <ItemGroup Condition=" '$(TraversalTranslateProjectFileItems)' != 'false' "> |
|
209 | 217 | SkipNonexistentTargets="$(SkipNonexistentTargets)" /> |
210 | 218 | </Target> |
211 | 219 |
|
| 220 | + <Target Name="VSTest" |
| 221 | + DependsOnTargets="$(VSTestDependsOn)"> |
| 222 | + |
| 223 | + <MSBuild Projects="@(PreTraversalProject)" |
| 224 | + Targets="VSTest" |
| 225 | + Properties="$(PreTraversalGlobalProperties)" |
| 226 | + Condition=" '@(PreTraversalProject)' != '' " |
| 227 | + BuildInParallel="$(BuildInParallel)" |
| 228 | + SkipNonexistentProjects="$(SkipNonexistentProjects)" |
| 229 | + SkipNonexistentTargets="$(SkipNonexistentTargets)" /> |
| 230 | + |
| 231 | + <MSBuild Projects="@(PreTraversalVSTestProject)" |
| 232 | + Targets="VSTest" |
| 233 | + Properties="$(PreTraversalVSTestGlobalProperties)" |
| 234 | + Condition=" '@(PreTraversalVSTestProject)' != '' " |
| 235 | + BuildInParallel="$(BuildInParallel)" |
| 236 | + SkipNonexistentProjects="$(SkipNonexistentProjects)" |
| 237 | + SkipNonexistentTargets="$(SkipNonexistentTargets)" /> |
| 238 | + |
| 239 | + <MSBuild Projects="@(_MSBuildProjectReferenceExistent)" |
| 240 | + Targets="VSTest" |
| 241 | + Properties="$(TraversalGlobalProperties);$(TraversalVSTestGlobalProperties)" |
| 242 | + BuildInParallel="$(BuildInParallel)" |
| 243 | + SkipNonexistentProjects="$(SkipNonexistentProjects)" |
| 244 | + SkipNonexistentTargets="$(SkipNonexistentTargets)" /> |
| 245 | + |
| 246 | + <MSBuild Projects="@(PostTraversalVSTestProject)" |
| 247 | + Targets="VSTest" |
| 248 | + Properties="$(PostTraversalVSTestGlobalProperties)" |
| 249 | + Condition=" '@(PostTraversalVSTestProject)' != '' " |
| 250 | + BuildInParallel="$(BuildInParallel)" |
| 251 | + SkipNonexistentProjects="$(SkipNonexistentProjects)" |
| 252 | + SkipNonexistentTargets="$(SkipNonexistentTargets)" /> |
| 253 | + |
| 254 | + <MSBuild Projects="@(PostTraversalProject)" |
| 255 | + Targets="VSTest" |
| 256 | + Properties="$(PostTraversalGlobalProperties)" |
| 257 | + Condition=" '@(PostTraversalProject)' != '' " |
| 258 | + BuildInParallel="$(BuildInParallel)" |
| 259 | + SkipNonexistentProjects="$(SkipNonexistentProjects)" |
| 260 | + SkipNonexistentTargets="$(SkipNonexistentTargets)" /> |
| 261 | + </Target> |
| 262 | + |
212 | 263 | <Target Name="Pack" |
213 | 264 | DependsOnTargets="$(PackDependsOn)"> |
214 | 265 |
|
|
251 | 302 | SkipNonexistentProjects="$(SkipNonexistentProjects)" |
252 | 303 | SkipNonexistentTargets="$(SkipNonexistentTargets)" /> |
253 | 304 | </Target> |
254 | | - |
| 305 | + |
| 306 | + <Target Name="Publish" |
| 307 | + DependsOnTargets="$(PublishDependsOn)"> |
| 308 | + |
| 309 | + <MSBuild Projects="@(PreTraversalProject)" |
| 310 | + Targets="Publish" |
| 311 | + Properties="$(PreTraversalGlobalProperties)" |
| 312 | + Condition=" '@(PreTraversalProject)' != '' " |
| 313 | + BuildInParallel="$(BuildInParallel)" |
| 314 | + SkipNonexistentProjects="$(SkipNonexistentProjects)" |
| 315 | + SkipNonexistentTargets="$(SkipNonexistentTargets)" /> |
| 316 | + |
| 317 | + <MSBuild Projects="@(PreTraversalPublishProject)" |
| 318 | + Targets="Publish" |
| 319 | + Properties="$(PreTraversalPublishGlobalProperties)" |
| 320 | + Condition=" '@(PreTraversalPublishProject)' != '' " |
| 321 | + BuildInParallel="$(BuildInParallel)" |
| 322 | + SkipNonexistentProjects="$(SkipNonexistentProjects)" |
| 323 | + SkipNonexistentTargets="$(SkipNonexistentTargets)" /> |
| 324 | + |
| 325 | + <MSBuild Projects="@(_MSBuildProjectReferenceExistent)" |
| 326 | + Targets="Publish" |
| 327 | + Properties="$(TraversalGlobalProperties);$(TraversalPublishGlobalProperties)" |
| 328 | + BuildInParallel="$(BuildInParallel)" |
| 329 | + SkipNonexistentProjects="$(SkipNonexistentProjects)" |
| 330 | + SkipNonexistentTargets="$(SkipNonexistentTargets)" /> |
| 331 | + |
| 332 | + <MSBuild Projects="@(PostTraversalPublishProject)" |
| 333 | + Targets="Publish" |
| 334 | + Properties="$(PostTraversalPublishGlobalProperties)" |
| 335 | + Condition=" '@(PostTraversalPublishProject)' != '' " |
| 336 | + BuildInParallel="$(BuildInParallel)" |
| 337 | + SkipNonexistentProjects="$(SkipNonexistentProjects)" |
| 338 | + SkipNonexistentTargets="$(SkipNonexistentTargets)" /> |
| 339 | + |
| 340 | + <MSBuild Projects="@(PostTraversalProject)" |
| 341 | + Targets="Publish" |
| 342 | + Properties="$(PostTraversalGlobalProperties)" |
| 343 | + Condition=" '@(PostTraversalProject)' != '' " |
| 344 | + BuildInParallel="$(BuildInParallel)" |
| 345 | + SkipNonexistentProjects="$(SkipNonexistentProjects)" |
| 346 | + SkipNonexistentTargets="$(SkipNonexistentTargets)" /> |
| 347 | + </Target> |
| 348 | + |
255 | 349 | <!-- |
256 | 350 | Traversal projects do not build anything and should not check for invalid configuration/platform. |
257 | 351 | --> |
|
0 commit comments