Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add helix-matrix.yml and windows arm 64 helix queue #22002

Merged
merged 28 commits into from
May 24, 2020
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
959bff1
Add helix-matrix.yml
HaoK May 19, 2020
35a2fb0
Setup helix pipeline
HaoK May 20, 2020
0c03ba7
Whitespace matters??
HaoK May 20, 2020
50d2369
Update helix-matrix.yml
HaoK May 20, 2020
cdc2554
Remove internal variables,
HaoK May 20, 2020
78f5c96
Remove non pr helix jobs from ci.yml
HaoK May 20, 2020
ae5d31b
Add -nobl
HaoK May 20, 2020
a88c8c0
Add windows arm64 queue
HaoK May 20, 2020
bf44690
Update helix-matrix.yml
HaoK May 20, 2020
65d4dc8
Clarify comments of queue groups
HaoK May 20, 2020
d0cef20
Try adding a win arm64 job too
HaoK May 21, 2020
c94de21
Update helix-matrix.yml
HaoK May 21, 2020
2d3e8b7
Try using dotnet5 feed
HaoK May 21, 2020
85da3c8
Update Microsoft.AspNetCore.NodeServices.Tests.csproj
HaoK May 21, 2020
65f38a3
Update NodeServicesTest.cs
HaoK May 21, 2020
527820b
ConditionalFact so skips work
HaoK May 21, 2020
911cfed
Update Diagnostics.EFCore.FunctionalTests.csproj
HaoK May 21, 2020
015d2df
Don't try to install sqlserverlocaldb on arm64
HaoK May 21, 2020
0f6b822
Add ability to skip specific queues in project
HaoK May 22, 2020
5e13c00
Update Microsoft.AspNetCore.Server.Kestrel.Transport.Libuv.Tests.csproj
HaoK May 22, 2020
5266ce3
Update Libuv.BindTests.csproj
HaoK May 22, 2020
ec6f73f
Update Libuv.FunctionalTests.csproj
HaoK May 22, 2020
ec53012
Harden situation where upload root is not set?
HaoK May 22, 2020
45ad30e
Update Helix.targets
HaoK May 22, 2020
fcd32d2
Update Helix.targets
HaoK May 22, 2020
d7e0fe1
Update Helix.targets
HaoK May 22, 2020
a9c171f
Update helix-matrix.yml
HaoK May 22, 2020
186dc46
Switch to cron triggers, add internal vars back
HaoK May 23, 2020
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
48 changes: 0 additions & 48 deletions .azure/pipelines/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -648,54 +648,6 @@ stages:
publishOnError: true
includeForks: true

- template: jobs/default-build.yml
parameters:
condition: notin(variables['Build.Reason'], 'PullRequest')
jobName: Helix_x64_daily
jobDisplayName: 'Tests: Helix x64 Daily'
agentOs: Windows
timeoutInMinutes: 180
steps:
# Build the shared framework
- script: ./build.cmd -ci -nobl -all -pack -arch x64 /p:ASPNETCORE_TEST_LOG_DIR=artifacts/log
displayName: Build shared fx
- script: .\restore.cmd -ci -nobl /p:BuildInteropProjects=true
displayName: Restore interop projects
- script: .\build.cmd -ci -nobl -NoRestore -test -all -projects eng\helix\helix.proj /p:IsHelixJob=true /p:IsHelixDaily=true /p:BuildInteropProjects=true /p:RunTemplateTests=true /p:ASPNETCORE_TEST_LOG_DIR=artifacts/log
displayName: Run build.cmd helix target
env:
HelixApiAccessToken: $(HelixApiAccessToken) # Needed for internal queues
SYSTEM_ACCESSTOKEN: $(System.AccessToken) # We need to set this env var to publish helix results to Azure Dev Ops
artifacts:
- name: Helix_logs
path: artifacts/log/
publishOnError: true
includeForks: true

# Helix ARM64
- template: jobs/default-build.yml
parameters:
condition: and(eq(variables['System.TeamProject'], 'public'), notin(variables['Build.Reason'], 'PullRequest'))
jobName: Helix_arm64_daily
jobDisplayName: "Tests: Helix ARM64 Daily"
agentOs: Linux
timeoutInMinutes: 180
steps:
# Build the shared framework
- script: ./restore.sh -ci -nobl
displayName: Restore
- script: ./build.sh -ci --nobl --arch arm64 -test --no-build-nodejs --all -projects $(Build.SourcesDirectory)/eng/helix/helix.proj /p:IsHelixJob=true /p:IsHelixDaily=true /p:ASPNETCORE_TEST_LOG_DIR=artifacts/log
displayName: Run build.sh helix arm64 target
env:
HelixApiAccessToken: $(HelixApiAccessToken) # Needed for internal queues
SYSTEM_ACCESSTOKEN: $(System.AccessToken) # We need to set this env var to publish helix results to Azure Dev Ops
installNodeJs: false
artifacts:
- name: Helix_arm64_logs
path: artifacts/log/
publishOnError: true
includeForks: true

# Source build
- job: Source_Build
displayName: 'Test: Linux Source Build'
Expand Down
63 changes: 63 additions & 0 deletions .azure/pipelines/helix-matrix.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
# We only want to run full helix matrix on master
pr: none
trigger: none
schedules:
- cron: "0 */12 * * *"
branches:
include:
- master
always: true

variables:
- ${{ if ne(variables['System.TeamProject'], 'internal') }}:
- name: _UseHelixOpenQueues
value: 'true'
HaoK marked this conversation as resolved.
Show resolved Hide resolved
- ${{ if eq(variables['System.TeamProject'], 'internal') }}:
- group: DotNet-HelixApi-Access
- name: _UseHelixOpenQueues
value: 'false'

jobs:
- template: jobs/default-build.yml
parameters:
jobName: Helix_matrix_x64
jobDisplayName: 'Tests: Helix full matrix x64'
agentOs: Windows
timeoutInMinutes: 240
steps:
# Build the shared framework
- script: ./build.cmd -ci -nobl -all -pack -arch x64 /p:ASPNETCORE_TEST_LOG_DIR=artifacts/log
displayName: Build shared fx
- script: .\restore.cmd -ci /p:BuildInteropProjects=true
displayName: Restore interop projects
- script: .\build.cmd -ci -nobl -NoRestore -test -noBuildJava -all -projects eng\helix\helix.proj /p:IsHelixDaily=true /p:IsRequiredCheck=true /p:IsHelixJob=true /p:BuildInteropProjects=true /p:RunTemplateTests=true /p:ASPNETCORE_TEST_LOG_DIR=artifacts/log
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I may have missed an earlier discussion. Why is -noBuildJava needed here?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good question, looks like we have a difference between the quarantined tests and what was in the normal ci.yml

I copied this from the quarantined test yml which had that...

https://github.com/dotnet/aspnetcore/blob/master/.azure/pipelines/quarantined-tests.yml#L38

@BrennanConroy do we need to build java for the signalr tests?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@BrennanConroy do we need to build java for the signalr tests?

I believe so. Also, is this pipeline running anywhere? I don't see a run of this.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should be here, https://dev.azure.com/dnceng/public/_build?definitionId=837&_a=summary

I'll add back the java flags on those pipelines

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah new pipeline name, that's why I didn't see it.

displayName: Run build.cmd helix target
env:
HelixApiAccessToken: $(HelixApiAccessToken) # Needed for internal queues
SYSTEM_ACCESSTOKEN: $(System.AccessToken) # We need to set this env var to publish helix results to Azure Dev Ops
artifacts:
- name: Helix_logs
path: artifacts/log/
publishOnError: true

# Helix ARM64
- template: jobs/default-build.yml
parameters:
jobName: Helix_matrix_arm64
jobDisplayName: "Tests: Helix ARM64 matrix"
agentOs: Linux
timeoutInMinutes: 180
steps:
- script: ./restore.sh -ci -nobl
displayName: Restore
- script: ./build.sh -ci --nobl --arch arm64 -test --no-build-nodejs --all -projects $(Build.SourcesDirectory)/eng/helix/helix.proj /p:IsHelixJob=true /p:IsHelixDaily=true /p:ASPNETCORE_TEST_LOG_DIR=artifacts/log
displayName: Run build.sh helix arm64 target
env:
HelixApiAccessToken: $(HelixApiAccessToken) # Needed for internal queues
SYSTEM_ACCESSTOKEN: $(System.AccessToken) # We need to set this env var to publish helix results to Azure Dev Ops
installNodeJs: false
artifacts:
- name: Helix_arm64_logs
path: artifacts/log/
publishOnError: true
includeForks: true
5 changes: 5 additions & 0 deletions eng/helix/content/RunTests/TestRunner.cs
Original file line number Diff line number Diff line change
Expand Up @@ -309,6 +309,11 @@ public void UploadResults()
}

var HELIX_WORKITEM_UPLOAD_ROOT = Environment.GetEnvironmentVariable("HELIX_WORKITEM_UPLOAD_ROOT");
if (string.IsNullOrEmpty(HELIX_WORKITEM_UPLOAD_ROOT))
{
Console.WriteLine("No HELIX_WORKITEM_UPLOAD_ROOT specified, skipping log copy");
return;
}
Console.WriteLine($"Copying artifacts/log/ to {HELIX_WORKITEM_UPLOAD_ROOT}/");
if (Directory.Exists("artifacts/log"))
{
Expand Down
4 changes: 2 additions & 2 deletions eng/helix/content/runtests.cmd
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@ echo "Installing Runtime"
powershell.exe -NoProfile -ExecutionPolicy unrestricted -Command "[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; &([scriptblock]::Create((Invoke-WebRequest -useb 'https://dot.net/v1/dotnet-install.ps1'))) -Architecture %$arch% -Runtime dotnet -Version %$runtimeVersion% -InstallDir %DOTNET_ROOT%"

set exit_code=0
echo "Restore: dotnet restore RunTests\RunTests.csproj --source https://api.nuget.org/v3/index.json --ignore-failed-sources..."
dotnet restore RunTests\RunTests.csproj --source https://api.nuget.org/v3/index.json --ignore-failed-sources
echo "Restore: dotnet restore RunTests\RunTests.csproj --source https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet5/nuget/v3/index.json --ignore-failed-sources..."
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@BrennanConroy I had to switch feeds for some of the packages to restore properly on the windows arm queue, not sure why?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Link to a failure otherwise I have no context to help

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That is super strange. I'm not against this change, but I would like to know why that package is trying to be resolved :D

dotnet restore RunTests\RunTests.csproj --source https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet5/nuget/v3/index.json --ignore-failed-sources

echo "Running tests: dotnet run --project RunTests\RunTests.csproj -- --target %$target% --sdk %$sdkVersion% --runtime %$runtimeVersion% --queue %$queue% --arch %$arch% --quarantined %$quarantined% --ef %$ef% --aspnetruntime %$aspnetruntime% --aspnetref %$aspnetref% --helixTimeout %$helixTimeout%..."
dotnet run --project RunTests\RunTests.csproj -- --target %$target% --sdk %$sdkVersion% --runtime %$runtimeVersion% --queue %$queue% --arch %$arch% --quarantined %$quarantined% --ef %$ef% --aspnetruntime %$aspnetruntime% --aspnetref %$aspnetref% --helixTimeout %$helixTimeout%
Expand Down
12 changes: 4 additions & 8 deletions eng/targets/Helix.Common.props
Original file line number Diff line number Diff line change
Expand Up @@ -18,14 +18,14 @@
<HelixPreCommand Include="call RunPowershell.cmd UpdateIISExpressCertificate.ps1 || exit /b 1" />
</ItemGroup>

<!-- ubuntu and win10 required for green PR queues -->
<!-- PR(ci.yaml) required queues -->
<ItemGroup Condition="'$(IsRequiredCheck)' == 'true' AND '$(TargetArchitecture)' == 'x64'">
<HelixAvailableTargetQueue Include="Ubuntu.1604.Amd64.Open" Platform="Linux" />
<HelixAvailableTargetQueue Include="Windows.10.Amd64.Open" Platform="Windows" />
<HelixAvailableTargetQueue Include="OSX.1014.Amd64.Open" Platform="Linux" />
</ItemGroup>

<!-- daily scheduled only queues -->
<!-- queues for helix-matrix.yml pipeline -->
<ItemGroup Condition="'$(IsWindowsOnlyTest)' != 'true' AND '$(TargetArchitecture)' == 'x64' AND '$(IsHelixDaily)' == 'true'">
<HelixAvailableTargetQueue Include="Windows.7.Amd64.Open" Platform="Windows" />
<HelixAvailableTargetQueue Include="Windows.81.Amd64.Open" Platform="Windows" />
Expand All @@ -37,13 +37,9 @@
<HelixAvailableTargetQueue Include="(Fedora.28.Amd64.Open)[email protected]/dotnet-buildtools/prereqs:fedora-28-helix-09ca40b-20190508143249" Platform="Linux" />
</ItemGroup>

<!-- arm64 queues for helix-matrix.yml pipeline -->
<ItemGroup Condition="'$(IsWindowsOnlyTest)' != 'true' AND '$(TargetArchitecture)' == 'arm64' AND '$(IsHelixDaily)' == 'true' AND '$(RunQuarantinedTests)' != 'true'">
<!-- arm64 queues -->
<HelixAvailableTargetQueue Include="Windows.10.Arm64.Open" Platform="Windows" />
<HelixAvailableTargetQueue Include="(Debian.9.Arm64.Open)[email protected]/dotnet-buildtools/prereqs:debian-9-helix-arm64v8-a12566d-20190807161036" Platform="Linux" />

<!-- Need to resolve permission issues on this docker queue
<HelixAvailableTargetQueue Include="(Alpine.38.Arm64)[email protected]/dotnet-buildtools/prereqs:alpine-3.8-helix-arm64v8-46e69dd-20190327215724" Platform="Linux" />
<HelixAvailableTargetQueue Include="(Ubuntu-1804.Arm64.Open)[email protected]/dotnet-buildtools/prereqs:ubuntu-18.04-helix-arm64v8-6f28fa9-20190606004102" Platform="Linux" />
-->
</ItemGroup>
</Project>
3 changes: 2 additions & 1 deletion eng/targets/Helix.targets
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<HelixPreCommand Condition="'$(IsWindowsHelixQueue)' != 'true' AND '$(IsMacHelixQueue)' != 'true'" Include="./installjdk.sh 10.0.2 x64 &amp;&amp; if [ &quot;%24JAVA_HOME&quot; = &quot;&quot; ]%3B then export JAVA_HOME=%24PWD/java%3B fi" />
</ItemGroup>

<ItemGroup Condition="'$(TestDependsOnMssql)' == 'true' AND '$(IsWindowsHelixQueue)' == 'true'">
<ItemGroup Condition="'$(TestDependsOnMssql)' == 'true' AND '$(IsWindowsHelixQueue)' == 'true' AND '$(TargetArchitecture)' != 'arm64'">
<HelixPreCommand Include="call RunPowershell.cmd mssql\InstallSqlServerLocalDB.ps1 || exit /b 1" />
</ItemGroup>

Expand Down Expand Up @@ -80,6 +80,7 @@ Usage: dotnet msbuild /t:Helix src/MyTestProject.csproj
<PropertyGroup>
<BuildHelixPayload Condition="'@(_HelixApplicableTargetQueue->Count())' == '0'">false</BuildHelixPayload>
<BuildHelixPayload Condition="'$(TargetArchitecture)' == 'arm64' AND '$(SkipHelixArm)' == 'true'">false</BuildHelixPayload>
<BuildHelixPayload Condition="$(SkipHelixQueues.Contains('$(HelixTargetQueue)'))">false</BuildHelixPayload>
</PropertyGroup>
</Target>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@
<!-- Avoid CS1705 errors due to mix of assemblies brought in transitively. -->
<Reference Include="Microsoft.Extensions.DependencyInjection.Abstractions" />
<Reference Include="Microsoft.Extensions.Logging.Abstractions" />

<Compile Include="$(SharedSourceRoot)test\SkipOnHelixAttribute.cs" />
</ItemGroup>

</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
<ItemGroup>
<Reference Include="Microsoft.AspNetCore.NodeServices" />
<Reference Include="Microsoft.AspNetCore.TestHost" />
<Compile Include="$(SharedSourceRoot)test\SkipOnHelixAttribute.cs" />
<Content Include="js\**\*" />
</ItemGroup>

Expand Down
16 changes: 9 additions & 7 deletions src/Middleware/NodeServices/test/NodeServicesTest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,14 @@
using System;
using System.IO;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Testing;
using Microsoft.AspNetCore.NodeServices.HostingModels;
using Microsoft.Extensions.DependencyInjection;
using Xunit;

namespace Microsoft.AspNetCore.NodeServices
{
[SkipOnHelix("https://github.com/dotnet/aspnetcore/issues/22084", Queues = "Windows.10.Arm64;Windows.10.Arm64.Open")]
dougbu marked this conversation as resolved.
Show resolved Hide resolved
[Obsolete("Use Microsoft.AspNetCore.SpaServices.Extensions")]
public class NodeServicesTest : IDisposable
{
Expand All @@ -26,7 +28,7 @@ public NodeServicesTest()
_nodeServices = NodeServicesFactory.CreateNodeServices(options);
}

[Fact]
[ConditionalFact]
public async Task CanGetSuccessResult()
{
// Act
Expand All @@ -38,7 +40,7 @@ public async Task CanGetSuccessResult()
Assert.Equal("test result", result);
}

[Fact]
[ConditionalFact]
public async Task CanGetErrorResult()
{
// Act/Assert
Expand All @@ -49,7 +51,7 @@ public async Task CanGetErrorResult()
Assert.StartsWith("This is an error from Node", ex.Message);
}

[Fact]
[ConditionalFact]
public async Task CanGetResultAsynchronously()
{
// Act
Expand All @@ -63,7 +65,7 @@ public async Task CanGetResultAsynchronously()
Assert.Equal("delayed test result", result);
}

[Fact]
[ConditionalFact]
public async Task CanPassParameters()
{
// Act
Expand All @@ -77,7 +79,7 @@ public async Task CanPassParameters()
Assert.Equal("Param0: Hey; Param1: 123", result);
}

[Fact]
[ConditionalFact]
public async Task CanPassParametersWithCamelCaseNameConversion()
{
// Act
Expand All @@ -90,7 +92,7 @@ public async Task CanPassParametersWithCamelCaseNameConversion()
Assert.Equal("Received: [{\"stringProp\":\"Abc\",\"intProp\":123,\"boolProp\":true}]", result);
}

[Fact]
[ConditionalFact]
public async Task CanReceiveComplexResultWithPascalCaseNameConversion()
{
// Act
Expand All @@ -104,7 +106,7 @@ public async Task CanReceiveComplexResultWithPascalCaseNameConversion()
Assert.True(result.BoolProp);
}

[Fact]
[ConditionalFact]
public async Task CanInvokeDefaultModuleExport()
{
// Act
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
<TargetFramework>$(DefaultNetCoreTargetFramework)</TargetFramework>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
<ServerGarbageCollection>true</ServerGarbageCollection>
<!-- https://github.com/dotnet/aspnetcore/issues/22114 -->
<SkipHelixQueues>Windows.10.Arm64;Windows.10.Arm64.Open</SkipHelixQueues>
</PropertyGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
<TargetFramework>$(DefaultNetCoreTargetFramework)</TargetFramework>
<ServerGarbageCollection>true</ServerGarbageCollection>
<TestGroupName>Libuv.BindTests</TestGroupName>
<!-- https://github.com/dotnet/aspnetcore/issues/22114 -->
<SkipHelixQueues>Windows.10.Arm64;Windows.10.Arm64.Open</SkipHelixQueues>
</PropertyGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@
<ServerGarbageCollection>true</ServerGarbageCollection>
<!-- Put this project into its own test group to avoid running parallel with other test projects. Libuv does not play nice with other test assemblies. -->
<TestGroupName>Libuv.FunctionalTests</TestGroupName>
<!-- https://github.com/dotnet/aspnetcore/issues/22114 -->
<SkipHelixQueues>Windows.10.Arm64;Windows.10.Arm64.Open</SkipHelixQueues>
</PropertyGroup>

<ItemGroup>
Expand Down