Skip to content

Commit d265580

Browse files
committed
[ci] Remove separate SmokeTests jobs.
1 parent 928e7b9 commit d265580

21 files changed

+17
-129
lines changed

build-tools/automation/azure-pipelines.yaml

Lines changed: 2 additions & 80 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ stages:
9393
- template: yaml-templates/build-linux.yaml
9494

9595
- stage: smoke_tests
96-
displayName: Smoke Tests
96+
displayName: Package Tests
9797
dependsOn: mac_build
9898
jobs:
9999
# Check - "Xamarin.Android (macOS > Tests > APKs Classic)"
@@ -453,80 +453,6 @@ stages:
453453

454454
- template: yaml-templates/fail-on-issue.yaml
455455

456-
# MSBuild Smoke Tests - Mac
457-
- template: yaml-templates/run-msbuild-tests.yaml
458-
parameters:
459-
testOS: macOS
460-
jobName: mac_smoke_msbuild_tests
461-
jobDisplayName: macOS > Tests > MSBuild
462-
agentCount: 2
463-
testFilter: cat = SmokeTests
464-
installApkDiff: true
465-
466-
# MSBuild Smoke Tests - Win
467-
- template: yaml-templates/run-msbuild-tests.yaml
468-
parameters:
469-
testOS: Windows
470-
jobName: win_smoke_msbuild_tests
471-
jobDisplayName: Windows > Tests > MSBuild
472-
agentCount: 2
473-
testFilter: cat = SmokeTests
474-
installApkDiff: true
475-
476-
# Check - "Xamarin.Android (macOS > Tests > MSBuild+Emulator)"
477-
- job: mac_msbuilddevice_tests
478-
displayName: macOS > Tests > MSBuild+Emulator One .NET
479-
pool:
480-
vmImage: $(HostedMacImage)
481-
timeoutInMinutes: 180
482-
workspace:
483-
clean: all
484-
steps:
485-
- template: yaml-templates/setup-test-environment.yaml
486-
parameters:
487-
provisionClassic: false
488-
provisionatorChannel: ${{ parameters.provisionatorChannel }}
489-
490-
- template: yaml-templates/run-xaprepare.yaml
491-
parameters:
492-
displayName: install emulator
493-
arguments: --s=EmulatorTestDependencies
494-
495-
- task: DownloadPipelineArtifact@2
496-
inputs:
497-
artifactName: $(TestAssembliesArtifactName)
498-
downloadPath: $(System.DefaultWorkingDirectory)/bin/Test$(XA.Build.Configuration)
499-
500-
- task: MSBuild@1
501-
displayName: start emulator
502-
inputs:
503-
solution: tests/Mono.Android-Tests/Mono.Android-Tests.csproj
504-
configuration: $(XA.Build.Configuration)
505-
msbuildArguments: /t:AcquireAndroidTarget /bl:$(System.DefaultWorkingDirectory)/bin/Test$(XA.Build.Configuration)/start-emulator.binlog
506-
507-
- template: yaml-templates/run-nunit-tests.yaml
508-
parameters:
509-
testRunTitle: MSBuildDeviceIntegration Smoke - macOS
510-
testAssembly: $(System.DefaultWorkingDirectory)/bin/Test$(XA.Build.Configuration)/MSBuildDeviceIntegration/$(DotNetStableTargetFramework)/MSBuildDeviceIntegration.dll
511-
dotNetTestExtraArgs: --filter "TestCategory = SmokeTests $(DotNetNUnitCategories)"
512-
testResultsFile: TestResult-MSBuildDeviceIntegrationSmoke-$(XA.Build.Configuration).xml
513-
514-
- task: MSBuild@1
515-
displayName: shut down emulator
516-
inputs:
517-
solution: tests/Mono.Android-Tests/Mono.Android-Tests.csproj
518-
configuration: $(XA.Build.Configuration)
519-
msbuildArguments: >-
520-
/t:AcquireAndroidTarget,ReleaseAndroidTarget
521-
/bl:$(System.DefaultWorkingDirectory)/bin/Test$(XA.Build.Configuration)/shutdown-emulator.binlog
522-
condition: always()
523-
524-
- template: yaml-templates/upload-results.yaml
525-
parameters:
526-
artifactName: Test Results - MSBuild Smoke With Emulator - macOS - One .NET
527-
528-
- template: yaml-templates/fail-on-issue.yaml
529-
530456
- stage: linux_tests
531457
displayName: Linux Tests
532458
dependsOn:
@@ -567,18 +493,14 @@ stages:
567493
- template: yaml-templates/fail-on-issue.yaml
568494

569495
- template: yaml-templates/stage-msbuild-tests.yaml
570-
parameters:
571-
stageCondition: and(succeeded(), or(eq(variables['RunAllTests'], true), contains(dependencies.mac_build.outputs['mac_build_create_installers.TestConditions.TestAreas'], 'MSBuild')))
572496

573497
- template: yaml-templates/stage-msbuild-emulator-tests.yaml
574-
parameters:
575-
stageCondition: and(succeeded(), or(eq(variables['RunAllTests'], true), contains(dependencies.mac_build.outputs['mac_build_create_installers.TestConditions.TestAreas'], 'MSBuildDevice')))
576498

577499
- stage: bcl_tests
578500
displayName: BCL Emulator Tests
579501
dependsOn: mac_build
580502
# Disabled on .NET release branches
581-
condition: and(succeeded(), eq(variables.IsRelOrTargetingRel, 'False'), or(eq(variables['RunAllTests'], true), contains(dependencies.mac_build.outputs['mac_build_create_installers.TestConditions.TestAreas'], 'BCL')))
503+
condition: and(succeeded(), eq(variables.IsRelOrTargetingRel, 'False'))
582504
jobs:
583505
# Check - "Xamarin.Android (macOS > Tests > BCL (Emulator))"
584506
- job: mac_bcl_tests

build-tools/automation/yaml-templates/build-macos.yaml

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -80,11 +80,3 @@ stages:
8080
xaSourcePath: $(System.DefaultWorkingDirectory)/xamarin-android
8181
artifactName: ${{ parameters.buildResultArtifactName }}
8282
includeBuildResults: true
83-
84-
- template: run-xaprepare.yaml
85-
parameters:
86-
arguments: --s=DetermineApplicableTests
87-
xaSourcePath: $(System.DefaultWorkingDirectory)/xamarin-android
88-
displayName: determine which test stages to run
89-
name: TestConditions
90-
condition: and(succeeded(), eq(variables['Build.DefinitionName'], 'Xamarin.Android-PR'))

build-tools/automation/yaml-templates/run-msbuild-tests.yaml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ parameters:
44
jobDisplayName: # Display name of the job
55
agentCount: # Number of build agents to run in parallel
66
testFilter: # Filter used to select tests (NUnit test selection language, not dotnet test filter language)
7-
installApkDiff: false # Smoke tests use apkdiff, others do not
87

98
jobs:
109
- job: ${{ parameters.jobName }}
@@ -30,7 +29,6 @@ jobs:
3029
parameters:
3130
provisionClassic: false
3231
installTestSlicer: true
33-
installApkDiff: ${{ parameters.installApkDiff }}
3432
installLegacyDotNet: false
3533
restoreNUnitConsole: false
3634
updateMono: false

build-tools/automation/yaml-templates/stage-msbuild-emulator-tests.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
parameters:
44
job_name: 'mac_dotnetdevice_tests'
5-
agent_count: 6
5+
agent_count: 8
66
stageCondition: succeeded()
77

88
stages:
@@ -50,7 +50,7 @@ stages:
5050
- template: run-sliced-nunit-tests.yaml
5151
parameters:
5252
testAssembly: $(System.DefaultWorkingDirectory)/bin/Test$(XA.Build.Configuration)/MSBuildDeviceIntegration/$(DotNetStableTargetFramework)/MSBuildDeviceIntegration.dll
53-
testFilter: cat != TimeZoneInfo & cat != Localization & cat != SmokeTests $(ExcludedNUnitCategories)
53+
testFilter: cat != TimeZoneInfo & cat != Localization $(ExcludedNUnitCategories)
5454
testRunTitle: MSBuildDeviceIntegration On Device - macOS
5555
testResultsTitle: TestResult-MSBuildDeviceIntegration-${{ parameters.job_name }}
5656

build-tools/automation/yaml-templates/stage-msbuild-tests.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,13 +14,13 @@ stages:
1414
testOS: macOS
1515
jobName: mac_msbuild_tests
1616
jobDisplayName: macOS > Tests > MSBuild
17-
agentCount: 8
18-
testFilter: cat != SmokeTests
17+
agentCount: 10
18+
testFilter: cat != Dummy # This is because $(ExcludedNUnitCategories) gets appended which starts with '&'
1919

2020
- template: run-msbuild-tests.yaml
2121
parameters:
2222
testOS: Windows
2323
jobName: win_msbuild_tests
2424
jobDisplayName: Windows > Tests > MSBuild
25-
agentCount: 4
26-
testFilter: cat != SmokeTests
25+
agentCount: 6
26+
testFilter: cat != Dummy # This is because $(ExcludedNUnitCategories) gets appended which starts with '&'

src/Xamarin.Android.Build.Tasks/Tests/Xamarin.Android.Build.Tests/AndroidUpdateResourcesTest.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,6 @@ public void BuildAppWithSystemNamespace ()
8787
}
8888

8989
[Test]
90-
[Category ("SmokeTests")]
9190
public void DesignTimeBuild ([Values(false, true)] bool isRelease, [Values (false, true)] bool useManagedParser, [Values (false, true)] bool useAapt2)
9291
{
9392
AssertAaptSupported (useAapt2);

src/Xamarin.Android.Build.Tasks/Tests/Xamarin.Android.Build.Tests/AotTests.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ void AssertProfiledAotBuildMessages(ProjectBuilder b)
5757
StringAssertEx.ContainsRegex (@$"Method.*emitted at", b.LastBuildOutput, "Should contain verbose AOT compiler output", RegexOptions.IgnoreCase);
5858
}
5959

60-
[Test, Category ("SmokeTests"), Category ("ProfiledAOT")]
60+
[Test, Category ("ProfiledAOT")]
6161
public void BuildBasicApplicationReleaseProfiledAot ([Values (true, false)] bool enableLLVM)
6262
{
6363
if (Builder.UseDotNet && enableLLVM) {
@@ -75,7 +75,7 @@ public void BuildBasicApplicationReleaseProfiledAot ([Values (true, false)] bool
7575
AssertProfiledAotBuildMessages (b);
7676
}
7777

78-
[Test, Category ("SmokeTests"), Category ("ProfiledAOT")]
78+
[Test, Category ("ProfiledAOT")]
7979
public void BuildBasicApplicationReleaseWithCustomAotProfile ()
8080
{
8181
var proj = new XamarinAndroidApplicationProject () {
@@ -255,7 +255,7 @@ public void BuildAotApplicationAndÜmläüts (string supportedAbis, bool enableL
255255

256256
[Test]
257257
[NonParallelizable]
258-
[Category ("SmokeTests"), Category ("XamarinBuildDownload")]
258+
[Category ("XamarinBuildDownload")]
259259
public void BuildAMassiveApp ()
260260
{
261261
var testPath = Path.Combine ("temp", "BuildAMassiveApp");

src/Xamarin.Android.Build.Tasks/Tests/Xamarin.Android.Build.Tests/BindingBuildTest.cs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ public class BindingBuildTest : BaseTest {
2222

2323
[Test]
2424
[TestCaseSource (nameof (ClassParseOptions))]
25-
[Category ("SmokeTests")]
2625
public void BuildBasicBindingLibrary (string classParser)
2726
{
2827
var targets = new List<string> {
@@ -154,7 +153,6 @@ public void BuildAarBindigLibraryWithNuGetPackageOfJar (string classParser)
154153
[Test]
155154
[TestCaseSource (nameof (ClassParseOptions))]
156155
[NonParallelizable]
157-
[Category ("SmokeTests")]
158156
public void BuildLibraryZipBindigLibraryWithAarOfJar (string classParser)
159157
{
160158
var proj = new XamarinAndroidBindingProject () {

src/Xamarin.Android.Build.Tasks/Tests/Xamarin.Android.Build.Tests/BuildTest.cs

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,6 @@ public void CheckMonoComponentsMask (bool enableProfiler, bool useInterpreter, b
100100
[Test]
101101
[TestCaseSource (nameof (CheckAssemblyCountsSource))]
102102
[NonParallelizable]
103-
[Category ("SmokeTests")]
104103
public void CheckAssemblyCounts (bool isRelease, bool aot)
105104
{
106105
var proj = new XamarinFormsAndroidApplicationProject {
@@ -145,7 +144,6 @@ public void CheckAssemblyCounts (bool isRelease, bool aot)
145144
// DotNet fails, see https://github.com/dotnet/runtime/issues/65484
146145
// Enable the commented out signature (and AOT) once the above is fixed
147146
[Test]
148-
[Category ("SmokeTests")]
149147
public void SmokeTestBuildWithSpecialCharacters ([Values (false, true)] bool forms, [Values (false /*, true*/)] bool aot)
150148
{
151149
var testName = "テスト";
@@ -281,7 +279,6 @@ public void CheckSequencePointGeneration (bool isRelease, bool monoSymbolArchive
281279

282280
[Test]
283281
[NonParallelizable]
284-
[Category ("SmokeTests")]
285282
public void BuildWithNativeLibraries ([Values (true, false)] bool isRelease)
286283
{
287284
var dll = new XamarinAndroidLibraryProject () {
@@ -409,7 +406,6 @@ public void BuildWithNativeLibraryUnknownAbi ()
409406
}
410407

411408
[Test]
412-
[Category ("SmokeTests")]
413409
public void BuildWithExternalJavaLibrary ()
414410
{
415411
var path = Path.Combine ("temp", TestName);
@@ -777,7 +773,7 @@ public interface OnFooListener
777773
}
778774

779775
[Test]
780-
[Category ("SmokeTests"), Category ("AOT")]
776+
[Category ("AOT")]
781777
[NonParallelizable]
782778
public void BuildApplicationWithSpacesInPath ([Values (true, false)] bool enableMultiDex, [Values ("", "r8")] string linkTool)
783779
{
@@ -1041,7 +1037,6 @@ public void CompileBeforeUpgradingNuGet ()
10411037
}
10421038

10431039
[Test]
1044-
[Category ("SmokeTests")]
10451040
[Category ("DotNetIgnore")] // .mdb and non-portable .pdb files not supported in .NET 5+
10461041
public void BuildBasicApplicationCheckPdb ()
10471042
{

src/Xamarin.Android.Build.Tasks/Tests/Xamarin.Android.Build.Tests/BuildTest2.cs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,6 @@ public void BuildBasicApplication ([ValueSource (nameof (SupportedTargetFramewor
117117
}
118118

119119
[Test]
120-
[Category ("SmokeTests")]
121120
public void BuildBasicApplicationThenMoveIt ([Values (true, false)] bool isRelease)
122121
{
123122
string path = Path.Combine (Root, "temp", TestName, "App1");
@@ -157,7 +156,6 @@ public static string GetLinkedPath (ProjectBuilder builder, bool isRelease, stri
157156
}
158157

159158
[Test]
160-
[Category ("SmokeTests")]
161159
public void BuildReleaseArm64 ([Values (false, true)] bool forms)
162160
{
163161
var proj = forms ?
@@ -511,7 +509,7 @@ public void DuplicateRJavaOutput ()
511509
}
512510

513511
[Test]
514-
[Category ("SmokeTests"), Category ("XamarinBuildDownload")]
512+
[Category ("XamarinBuildDownload")]
515513
[NonParallelizable] // parallel NuGet restore causes failures
516514
public void BuildXamarinFormsMapsApplication ([Values (true, false)] bool multidex)
517515
{

0 commit comments

Comments
 (0)