Skip to content
This repository has been archived by the owner on May 15, 2024. It is now read-only.

Add compliance to buildpipline #2086

Merged
merged 28 commits into from
Apr 19, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
27f7df8
Add compliance to buildpipline
jfversluis Apr 18, 2023
565d310
Update azure-pipelines.yml
jfversluis Apr 18, 2023
6122314
Update azure-pipelines.yml
jfversluis Apr 18, 2023
905cbc3
Fix
jfversluis Apr 18, 2023
dfa8a02
Move files to right place
jfversluis Apr 18, 2023
6fd5f80
Remove localization checks
jfversluis Apr 18, 2023
c170dcf
Remove gdn supression file
jfversluis Apr 18, 2023
953abd1
Renamine devopsnuget.config to nuget.config
jfversluis Apr 18, 2023
48fe60b
Remove references to NuGet.config from cake
jfversluis Apr 18, 2023
eba9f42
Revert "Remove references to NuGet.config from cake"
jfversluis Apr 18, 2023
134186a
Revert "Renamine devopsnuget.config to nuget.config"
jfversluis Apr 18, 2023
8018a07
Add GDN suppress file
jfversluis Apr 18, 2023
10d0c38
Create NuGet.config
jfversluis Apr 18, 2023
981b5d7
dotnet tool restore first
jfversluis Apr 19, 2023
5f984e0
Revert "dotnet tool restore first"
jfversluis Apr 19, 2023
fd44f7d
Use cake 2.1.0
jfversluis Apr 19, 2023
d4a5e41
Hmm more cake
jfversluis Apr 19, 2023
7db9187
Fix iOS Device Tests
jfversluis Apr 19, 2023
0b20bac
Revert "Fix iOS Device Tests"
jfversluis Apr 19, 2023
1138d28
Use Xcode 13.3
jfversluis Apr 19, 2023
7b5ab9c
Revert "Use Xcode 13.3"
jfversluis Apr 19, 2023
53f3555
Use macos-12 for iOS tests
jfversluis Apr 19, 2023
d308860
Revert "Revert "Use Xcode 13.3""
jfversluis Apr 19, 2023
68a6362
Xcode 14.2
jfversluis Apr 19, 2023
268970a
Try fix iOS tests
jfversluis Apr 19, 2023
4966b92
Update build.cake
jfversluis Apr 19, 2023
8ca9ed3
Update build.cake
jfversluis Apr 19, 2023
450d3a3
Bump xharness
jfversluis Apr 19, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion DeviceTests/DeviceTests.Android/DeviceTests.Android.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@
<PackageReference Include="System.Numerics.Vectors" Version="4.5.0" />
<PackageReference Include="xunit" Version="2.4.1" />
<PackageReference Include="xunit.runner.devices" Version="2.5.25" />
<PackageReference Include="Microsoft.DotNet.XHarness.TestRunners.Xunit" Version="1.0.0-prerelease.21620.1" />
<PackageReference Include="Microsoft.DotNet.XHarness.TestRunners.Xunit" Version="1.0.0-prerelease.23212.1" />
<PackageReference Include="Xamarin.AndroidX.MediaRouter" Version="1.2.0.1" />
<PackageReference Include="Xamarin.AndroidX.Palette" Version="1.0.0.6" />
</ItemGroup>
Expand Down
2 changes: 1 addition & 1 deletion DeviceTests/DeviceTests.iOS/DeviceTests.iOS.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@
<PackageReference Include="Xamarin.Forms" Version="5.0.0.2083" />
<PackageReference Include="xunit" Version="2.4.1" />
<PackageReference Include="xunit.runner.devices" Version="2.5.25" />
<PackageReference Include="Microsoft.DotNet.XHarness.TestRunners.Xunit" Version="1.0.0-prerelease.21620.1" />
<PackageReference Include="Microsoft.DotNet.XHarness.TestRunners.Xunit" Version="1.0.0-prerelease.23212.1" />
<PackageReference Include="System.Numerics.Vectors" Version="4.5.0" />
</ItemGroup>
<ItemGroup>
Expand Down
4 changes: 4 additions & 0 deletions DeviceTests/DeviceTests.iOS/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -57,5 +57,9 @@
<string>Access to your location is required for cool things to happen!</string>
<key>NSContactsUsageDescription</key>
<string>Contacts</string>
<key>UIRequiredDeviceCapabilities</key>
<array>
<string>arm64</string>
</array>
</dict>
</plist>
4 changes: 2 additions & 2 deletions DeviceTests/build.cake
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@

var TARGET = Argument("target", "Default");

var IOS_SIM_NAME = Argument("ios-device", EnvironmentVariable("IOS_SIM_NAME") ?? "iPhone 11");
var IOS_SIM_RUNTIME = Argument("ios-runtime", EnvironmentVariable("IOS_SIM_RUNTIME") ?? "com.apple.CoreSimulator.SimRuntime.iOS-14-2");
var IOS_SIM_NAME = Argument("ios-device", EnvironmentVariable("IOS_SIM_NAME") ?? "iPhone 14");
var IOS_SIM_RUNTIME = Argument("ios-runtime", EnvironmentVariable("IOS_SIM_RUNTIME") ?? "ios-simulator-64");
var IOS_PROJ = "./DeviceTests.iOS/DeviceTests.iOS.csproj";
var IOS_BUNDLE_ID = "com.xamarin.essentials.devicetests";
var IOS_IPA_PATH = "./DeviceTests.iOS/bin/iPhoneSimulator/Release/XamarinEssentialsDeviceTestsiOS.app";
Expand Down
12 changes: 12 additions & 0 deletions NuGet.config
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<packageSources>
<clear/>
<add key="dotnet-eng" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet-eng/nuget/v3/index.json" protocolVersion="3" />
<add key="dotnet-public" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet-public/nuget/v3/index.json" protocolVersion="3" />
<add key="dotnet6" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet6/nuget/v3/index.json" />
</packageSources>
<activePackageSource>
<add key="All" value="(Aggregate source)" />
</activePackageSource>
</configuration>
25 changes: 24 additions & 1 deletion azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ variables:
GIT_SHA: $(Build.SourceVersion)
GIT_BRANCH_NAME: $(Build.SourceBranchName)
AREA_PATH: 'DevDiv\Xamarin SDK\Build and Tools'
CAKE_VERSION: '2.1.0'

resources:
repositories:
Expand All @@ -36,8 +37,10 @@ stages:
jobs:
- template: .ci/build.v1.yml@components
parameters:
runChecks: false
dotnet: '3.1.415'
dotnetStable: '3.1.415'
cake: '2.1.0'
${{ if eq(variables['System.TeamProject'], 'devdiv') }}: # The AzurePipelines-EO pool is only available in DevDiv
windowsAgentPoolName: AzurePipelines-EO
windowsImage: '' # Override the 'windows-latest' default settings
Expand Down Expand Up @@ -92,6 +95,16 @@ stages:
packageFilter: '*.nupkg'
packageVersionRegex: '(?i)^Xamarin.Essentials\.(?<version>\d+\.\d+\.\d+)(.*).nupkg$'

- ${{ if eq(variables['System.TeamProject'], 'devdiv') }}:
- template: security/full/v0.yml@internal-templates
parameters:
dependsOn: [ ]
credScanSuppressionFile: $(Build.SourcesDirectory)\build-tools\automation\guardian\CredScanSuppressions.json
sourceGdnSuppressionFile: $(Build.SourcesDirectory)\build-tools\automation\guardian\source.gdnsuppress
tsaConfigFile: $(Build.SourcesDirectory)\build-tools\automation\guardian\tsaoptions-v2.json
policheckExclusionFilesFolder: $(Build.SourcesDirectory)\build-tools\automation\guardian
policheckGdnSuppressionFilesFolder: $(Build.SourcesDirectory)\build-tools\automation\guardian

- ${{ if not(startsWith(variables['Build.SourceBranch'], 'refs/tags/')) }}:
- stage: devicetests
displayName: Device Tests
Expand Down Expand Up @@ -124,6 +137,7 @@ stages:

- template: .ci/build.v1.yml@components
parameters:
macosImage: 'macos-12'
name: devicetests_ios
runChecks: false
displayName: iOS
Expand All @@ -133,7 +147,9 @@ stages:
verbosity: diagnostic
cakeFile: DeviceTests/build.cake
cakeTarget: test-ios-emu
xharness: '1.0.0-prerelease.21620.1'
cake: $(CAKE_VERSION)
xcode: '14.2'
xharness: '1.0.0-prerelease.23212.1'

- template: .ci/build.v1.yml@components
parameters:
Expand All @@ -147,6 +163,7 @@ stages:
cakeFile: DeviceTests/build.cake
cakeTarget: test-android-emu
cakeExtraArgs: --avd-target="`"system-images;android-21;google_apis;x86`""
cake: $(CAKE_VERSION)
preBuildSteps:
- bash: sh -c "echo \"y\" | $ANDROID_HOME/tools/bin/sdkmanager \"system-images;android-21;google_apis;x86\""
displayName: Install the Android emulators
Expand All @@ -163,6 +180,7 @@ stages:
cakeFile: DeviceTests/build.cake
cakeTarget: test-android-emu
cakeExtraArgs: --avd-target="`"system-images;android-22;google_apis;x86`""
cake: $(CAKE_VERSION)
preBuildSteps:
- bash: sh -c "echo \"y\" | $ANDROID_HOME/tools/bin/sdkmanager \"system-images;android-22;google_apis;x86\""
displayName: Install the Android emulators
Expand All @@ -180,6 +198,7 @@ stages:
# cakeFile: DeviceTests/build.cake
# cakeTarget: test-android-emu
# cakeExtraArgs: --avd-target="`"system-images;android-23;google_apis;x86`""
# cake: $(CAKE_VERSION)
# preBuildSteps:
# - bash: sh -c "echo \"y\" | $ANDROID_HOME/tools/bin/sdkmanager \"system-images;android-23;google_apis;x86\""
# displayName: Install the Android emulators
Expand All @@ -196,6 +215,7 @@ stages:
cakeFile: DeviceTests/build.cake
cakeTarget: test-android-emu
cakeExtraArgs: --avd-target="`"system-images;android-24;google_apis;x86`""
cake: $(CAKE_VERSION)
preBuildSteps:
- bash: sh -c "echo \"y\" | $ANDROID_HOME/tools/bin/sdkmanager \"system-images;android-24;google_apis;x86\""
displayName: Install the Android emulators
Expand All @@ -212,6 +232,7 @@ stages:
cakeFile: DeviceTests/build.cake
cakeTarget: test-android-emu
cakeExtraArgs: --avd-target="`"system-images;android-26;google_apis;x86`""
cake: $(CAKE_VERSION)
preBuildSteps:
- bash: sh -c "echo \"y\" | $ANDROID_HOME/tools/bin/sdkmanager \"system-images;android-26;google_apis;x86\""
displayName: Install the Android emulators
Expand All @@ -228,6 +249,7 @@ stages:
cakeFile: DeviceTests/build.cake
cakeTarget: test-android-emu
cakeExtraArgs: --avd-target="`"system-images;android-29;google_apis;x86`""
cake: $(CAKE_VERSION)
preBuildSteps:
- bash: sh -c "echo \"y\" | $ANDROID_HOME/tools/bin/sdkmanager \"system-images;android-29;google_apis;x86\""
displayName: Install the Android emulators
Expand All @@ -244,6 +266,7 @@ stages:
# cakeFile: DeviceTests/build.cake
# cakeTarget: test-android-emu
# cakeExtraArgs: --avd-target="`"system-images;android-30;google_apis;x86`""
# cake: $(CAKE_VERSION)
# preBuildSteps:
# - bash: sh -c "echo \"y\" | $ANDROID_HOME/tools/bin/sdkmanager \"system-images;android-30;google_apis;x86\""
# displayName: Install the Android emulators
6 changes: 6 additions & 0 deletions build-tools/automation/guardian/CredScanSuppressions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"tool": "Credential Scanner",
"suppressions": [

]
}
Loading