Skip to content

[tests] Hosting.Azure tests broken after the move to snapshot based tests #9024

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

Open
radical opened this issue Apr 29, 2025 · 4 comments
Open
Labels
area-engineering-systems infrastructure helix infra engineering repo stuff blocking-clean-ci Blocking a green CI testing ☑️

Comments

@radical
Copy link
Member

radical commented Apr 29, 2025

Aspire.Hosting.Azure.Tests broke after the two PRs for moving to snapshot based testing - #8930 and #9009 .

https://dev.azure.com/dnceng-public/public/_build/results?buildId=1029256&view=logs&j=dc0c59fc-6459-516f-9358-56938432eb13&t=bd6402dd-1caa-5b2e-8254-6909970e2dbf
https://dev.azure.com/dnceng-public/public/_build/results?buildId=1029334&view=ms.vss-test-web.build-test-results-tab

cc @RussKie @danmoseley

Failures from the first commit:
Windows:

failed Aspire.Hosting.Azure.Tests.AzureProvisioningResourceExtensionsTests.AsProvisioningParameterTests (2s 522ms)
  Xunit.Runner.InProc.SystemConsole.TestingPlatform.XunitException: VerifyException : Directory: D:\a\_work\1\s\tests\Aspire.Hosting.Azure.Tests
  New:
    - Received: AzureProvisioningResourceExtensionsTests.AsProvisioningParameterTests.received.bicep
      Verified: AzureProvisioningResourceExtensionsTests.AsProvisioningParameterTests.verified.bicep
  
  FileContent:
  
  New:
  
  Received: AzureProvisioningResourceExtensionsTests.AsProvisioningParameterTests.received.bicep
  @description('The location for the resource(s) to be deployed.')
  param location string = resourceGroup().location
  
  param endpointAddressParam string
  
  param someExpressionParam string
  
  resource app 'Microsoft.App/containerApps@2024-03-01' = {
    name: take('app-${uniqueString(resourceGroup().id)}', 32)
    location: location
    properties: {
      template: {
        scale: {
          rules: [
            {
              name: 'temp'
              custom: {
                type: 'external'
                metadata: {
                  address: endpointAddressParam
                  someExpression: someExpressionParam
                }
              }
            }
          ]
        }
      }
    }
  }

Linux:

failed Aspire.Hosting.Azure.Tests.AzureProvisioningResourceExtensionsTests.AsProvisioningParameterTests (66ms)
  Xunit.Runner.InProc.SystemConsole.TestingPlatform.XunitException: System.UnauthorizedAccessException : Access to the path '/mnt/vss' is denied.
  ---- System.IO.IOException : Permission denied
    at System.IO.FileSystem.CreateParentsAndDirectory(String fullPath, UnixFileMode unixCreateMode)
    at System.IO.FileSystem.CreateDirectory(String fullPath, UnixFileMode unixCreateMode)
    at System.IO.Directory.CreateDirectory(String path)
    at IoHelpers.CreateDirectory(String directory) in /_/src/Verify/IoHelpers.cs:94
    at VerifyTests.InnerVerifier.ResolveDirectory(String sourceFile, VerifySettings settings, PathInfo pathInfo) in /_/src/Verify/Verifier/InnerVerifier.cs:368
    at VerifyTests.InnerVerifier..ctor(String sourceFile, VerifySettings settings, String typeName, String methodName, IReadOnlyList`1 methodParameters, PathInfo pathInfo) in /_/src/Verify/Verifier/InnerVerifier.cs:58
    at VerifyXunit.Verifier.BuildVerifier(VerifySettings settings, String sourceFile, Boolean useUniqueDirectory) in /_/src/Verify.XunitV3/Verifier.cs:25
    at VerifyXunit.Verifier.<>c__DisplayClass10_0.<<Verify>b__0>d.MoveNext() in /_/src/Verify.XunitV3/Verifier.cs:99
    --- End of stack trace from previous location ---
    at Aspire.Hosting.Azure.Tests.AzureProvisioningResourceExtensionsTests.AsProvisioningParameterTests() in /mnt/vss/_work/1/s/tests/Aspire.Hosting.Azure.Tests/AzureProvisioningResourceExtensionsTests.cs:62
    --- End of stack trace from previous location ---
    ----- Inner Stack Trace -----

Report

Summary

24-Hour Hit Count 7-Day Hit Count 1-Month Count
0 0 0
@github-actions github-actions bot added the area-engineering-systems infrastructure helix infra engineering repo stuff label Apr 29, 2025
@danmoseley
Copy link
Member

is the learning here -- before making changes of this scale (if they're worthwhile), let's kick off a private azdo run?

@radical
Copy link
Member Author

radical commented Apr 29, 2025

is the learning here -- before making changes of this scale (if they're worthwhile), let's kick off a private azdo run?

Yes, definitely. Any infrastructure stuff that isn't github actions specific, or any big test changes should get a azdo run.

@RussKie
Copy link
Member

RussKie commented Apr 29, 2025

:O
Are the verified files pushed to Helix? Or is there something we need to do to push them there?

@radical
Copy link
Member Author

radical commented Apr 29, 2025

:O Are the verified files pushed to Helix? Or is there something we need to do to push them there?

You can add them as payload for the helix jobs like:

<ItemGroup Condition="'$(NeedsPlaywright)' == 'true' and '$(DisablePlaywrightTests)' != 'true'">
<HelixCorrelationPayload Include="$(PlaywrightDependenciesDirectory)" Destination="playwright-deps" />

Add them in tests/helix/send-to-helix-basictests.targets.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-engineering-systems infrastructure helix infra engineering repo stuff blocking-clean-ci Blocking a green CI testing ☑️
Projects
None yet
Development

No branches or pull requests

3 participants