Skip to content

Commit ef57c27

Browse files
praveensripraveensri
praveensri
authored and
praveensri
committed
pipeline changes
1 parent 71e1058 commit ef57c27

File tree

1 file changed

+30
-25
lines changed

1 file changed

+30
-25
lines changed

azure-pipelines.yml

+30-25
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,37 @@
1-
# Starter pipeline
2-
- task: DotNetCoreCLI@2
3-
inputs:
4-
command: 'build'
5-
- task: VSTest@2
6-
inputs:
7-
testSelector: 'testAssemblies'
8-
testAssemblyVer2: |
9-
**\*test*.dll
10-
!**\*TestAdapter.dll
11-
!**\obj\**
12-
searchFolder: '$(System.DefaultWorkingDirectory)'
13-
projects: 'dirs.sln'
14-
# Start with a minimal pipeline that you can customize to build and deploy your code.
15-
# Add steps that build, run tests, deploy, and more:
16-
# https://aka.ms/yaml
17-
181
trigger:
19-
- main
2+
- CosmosDB
203

214
pool:
22-
vmImage: ubuntu-latest
5+
vmImage: 'windows-latest'
6+
7+
variables:
8+
solution: '**/dirs.sln'
9+
buildPlatform: 'Any CPU'
10+
buildConfiguration: 'Release'
2311

2412
steps:
25-
- script: echo Hello, world!
26-
displayName: 'Run a one-line script'
2713

28-
- script: |
29-
echo Add other tasks to build, test, and deploy your project.
30-
echo See https://aka.ms/yaml
31-
displayName: 'Run a multi-line script'
14+
- task: NuGetToolInstaller@1
15+
16+
- task: NuGetCommand@2
17+
inputs:
18+
restoreSolution: '$(solution)'
3219

20+
- task: VSBuild@1
21+
inputs:
22+
solution: '$(solution)'
23+
msbuildArgs: '/p:DeployOnBuild=false /p:WebPublishMethod=Package /p:PackageAsSingleFile=true /p:SkipInvalidConfigurations=true /p:DesktopBuildPackageLocation="$(build.artifactStagingDirectory)\WebApp.zip" /p:DeployIisAppPath="Default Web Site"'
24+
platform: '$(buildPlatform)'
25+
configuration: '$(buildConfiguration)'
26+
27+
- task: VSTest@2
28+
inputs:
29+
platform: '$(buildPlatform)'
30+
configuration: '$(buildConfiguration)'
31+
32+
- script: dotnet test dirs.sln --logger trx
33+
- task: PublishTestResults@2
34+
condition: succeededOrFailed()
35+
inputs:
36+
testRunner: VSTest
37+
testResultsFiles: '**/*.trx'

0 commit comments

Comments
 (0)