1010
1111# Global variables
1212variables :
13- DotNetCoreVersion : 3.1.201
13+ DotNetCoreVersion : 3.1.300
1414 HostedMac : Hosted Mac Internal
1515 HostedWinVS2019 : Hosted Windows 2019 with VS2019
1616
2525 - checkout : self
2626 submodules : recursive
2727
28- - task : UseDotNet@2
29- displayName : Use .NET Core $(DotNetCoreVersion)
30- inputs :
31- version : $(DotNetCoreVersion)
28+ - template : templates\install-dependencies.yaml
3229
3330 - task : NuGetToolInstaller@0
3431 inputs :
@@ -78,71 +75,13 @@ jobs:
7875 - checkout : self
7976 submodules : recursive
8077
81- - task : UseDotNet@2
82- displayName : Use .NET Core $(DotNetCoreVersion)
83- inputs :
84- version : $(DotNetCoreVersion)
85-
86- - task : DotNetCoreCLI@2
87- displayName : Prepare Solution
88- inputs :
89- projects : Java.Interop.sln
90- arguments : ' -c $(Build.Configuration) -target:Prepare'
91-
92- - task : DotNetCoreCLI@2
93- displayName : Build Solution
94- inputs :
95- projects : Java.Interop.sln
96- arguments : ' -c $(Build.Configuration)'
97-
98- - task : DotNetCoreCLI@2
99- displayName : ' Tests: Java.Interop.Tools.Generator'
100- inputs :
101- command : test
102- arguments : bin\Test$(Build.Configuration)\Java.Interop.Tools.Generator-Tests.dll
103- continueOnError : true
104-
105- - task : DotNetCoreCLI@2
106- displayName : ' Tests: generator'
107- inputs :
108- command : test
109- arguments : bin\Test$(Build.Configuration)\generator-Tests.dll
110- continueOnError : true
111-
112- - task : DotNetCoreCLI@2
113- displayName : ' Tests: JavaCallableWrappers'
114- inputs :
115- command : test
116- arguments : bin\Test$(Build.Configuration)\Java.Interop.Tools.JavaCallableWrappers-Tests.dll
117- continueOnError : true
78+ - template : templates\install-dependencies.yaml
11879
119- - task : DotNetCoreCLI@2
120- displayName : ' Tests: logcat-parse'
121- inputs :
122- command : test
123- arguments : bin\Test$(Build.Configuration)\logcat-parse-Tests.dll
124- continueOnError : true
80+ - template : templates\core-build.yaml
12581
126- - task : DotNetCoreCLI@2
127- displayName : ' Tests: ApiXmlAdjuster'
128- inputs :
129- command : test
130- arguments : bin\Test$(Build.Configuration)\Xamarin.Android.Tools.ApiXmlAdjuster-Tests.dll
131- continueOnError : true
82+ - template : templates\core-tests.yaml
13283
133- - task : DotNetCoreCLI@2
134- displayName : ' Tests: Bytecode'
135- inputs :
136- command : test
137- arguments : bin\Test$(Build.Configuration)\Xamarin.Android.Tools.Bytecode-Tests.dll
138- continueOnError : true
139-
140- - powershell : |
141- Write-Host "Current job status is: $env:AGENT_JOBSTATUS"
142- if ($env:AGENT_JOBSTATUS -eq "SucceededWithIssues") {
143- Write-Host "##vso[task.complete result=Failed;]DONE"
144- }
145- displayName: Fail job if tests failed
84+ - template : templates\fail-on-issue.yaml
14685
14786- job : mac_build
14887 displayName : Mac - Mono
@@ -154,15 +93,7 @@ jobs:
15493 - checkout : self
15594 submodules : recursive
15695
157- - task : UseDotNet@2
158- displayName : Use .NET Core $(DotNetCoreVersion)
159- inputs :
160- version : $(DotNetCoreVersion)
161-
162- - script : |
163- dotnet tool install --global boots
164- boots --stable Mono
165- displayName: Install Mono-Stable
96+ - template : templates\install-dependencies.yaml
16697
16798 - script : make prepare CONFIGURATION=$(Build.Configuration)
16899 displayName : make prepare
@@ -200,3 +131,24 @@ jobs:
200131 inputs :
201132 ArtifactName : debug
202133 condition : succeededOrFailed()
134+
135+ - job : mac_dotnet_build
136+ displayName : Mac - .NET Core
137+ pool : $(HostedMac)
138+ timeoutInMinutes : 20
139+ workspace :
140+ clean : all
141+ steps :
142+ - checkout : self
143+ submodules : recursive
144+
145+ - template : templates\install-dependencies.yaml
146+
147+ - script : make prepare-core CONFIGURATION=$(Build.Configuration)
148+ displayName : make prepare-core
149+
150+ - template : templates\core-build.yaml
151+
152+ - template : templates\core-tests.yaml
153+
154+ - template : templates\fail-on-issue.yaml
0 commit comments