dotnet / dotnet/sdk

BlazorWasm tests fail due to Microsoft.Extensions inbox change

Open
#53,794 0 comments 0 reactions 0 assignees View on GitHub
Area-StaticWebAssets Test Debt
Dominant language
C#
Stars
3.2k
Forks
1.3k
PR merge metrics
PR metrics pending

Description

## Description

Multiple BlazorWasm Static Web Assets integration tests and the BlazorWasm global usings test fail due to the `Microsoft.Extensions.*.Abstractions` inbox change (`dotnet/dotnet#5206`) that baked into the bootstrap SDK.

### Static Web Assets baseline failures

The BlazorWasm SWA integration tests compare generated manifests against stored JSON baselines. The Extensions inbox change alters the set of DLLs that appear as WASM framework assets (e.g., compressed `.wasm.gz`/`.wasm.br` variants), causing the baselines to drift.

**Fix:** Regenerate baselines with `ASPNETCORE_TEST_BASELINES=true` using a bootstrap SDK that includes the inbox change.

### CS0012 compilation failure

`GivenThatWeWantToGenerateGlobalUsings_BlazorWasm.It_generates_blazorwasm_usings_and_builds_successfully` fails with CS0012 because the test references `Microsoft.AspNetCore.Components.WebAssembly` v5.0.0 against net11.0. Types from `Microsoft.Extensions.*` assemblies that moved inbox are no longer resolvable through the old package's assembly references.

## Affected Tests

- `BlazorWasmStaticWebAssetsIntegrationTest.StaticWebAssets_Build_Hosted_Works`
- `BlazorWasmStaticWebAssetsIntegrationTest.StaticWebAssets_BuildMinimal_Works`
- `BlazorWasmStaticWebAssetsIntegrationTest.StaticWebAssets_Publish_Hosted_Works`
- `BlazorWasmStaticWebAssetsIntegrationTest.StaticWebAssets_PublishMinimal_Works`
- `BlazorWasmStaticWebAssetsIntegrationTest.StaticWebAssets_Publish_DoesNotIncludeXmlDocumentationFiles_AsAssets`
- `GivenThatWeWantToGenerateGlobalUsings_BlazorWasm.It_generates_blazorwasm_usings_and_builds_successfully`

## Build

https://dev.azure.com/dnceng-public/public/_build/results?buildId=1373051
Helix job: `d9fc0bd3-ff11-45e2-aa54-6c468495f55d`, work item: `Microsoft.NET.Sdk.BlazorWebAssembly.Tests.dll.1`

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.