Skip to content

[Known Build Error] RunFileTests csc-only mode fails expecting binary log warning that is not emitted #53869

@jkoritzinsky

Description

@jkoritzinsky

Build Information

Build: https://dev.azure.com/dnceng-public/public/_build/results?buildId=1378681
Build error leg or test failing: dotnet.Tests.dll.20, dotnet.Tests.dll.21, dotnet.Tests.dll.11
Pull request: #53635

Error Message

{
  "ErrorMessage": "Binary log option was specified but MSBuild will be skipped because running just csc is enough",
  "ErrorPattern": "",
  "BuildRetry": true,
  "ExcludeConsoleLog": false
}

Details

Multiple dotnet run file-mode tests that use cscOnly: True with -bl fail because they expect the output to contain the warning:

Warning: Binary log option was specified but MSBuild will be skipped because running just csc is enough. Specify '--no-cache' to force full build.

But the warning is not emitted, causing assertion failures.

Affected tests:

  • Microsoft.DotNet.Cli.Run.Tests.RunFileTests_BuildOptions.WorkingDirectory(cscOnly: True)
  • Microsoft.DotNet.Cli.Run.Tests.RunFileTests_CscOnlyAndApi.CscOnly
  • Microsoft.DotNet.Cli.Run.Tests.RunFileTests_BuildCommands.LaunchProfile(cscOnly: True, relativePath: "Properties/launchSettings.json")

Reproduces on main — confirmed in builds:

Sample error (WorkingDirectory test):

Expected string to be the same string because Command did not output with Expected Output.
Expected: Warning: Binary log option was specified but MSBuild will be skipped because running just csc is enough. Specify '--no-cache' to force full build.
v1

Sample error (LaunchProfile test):

Expected string "Using launch settings from ...\launchSettings.json...
Hello from Program
Message: 'TestProfileMessage1'" to contain "Warning: Binary log option was specified but MSBuild will be skipped because running just csc is enough. Specify '--no-cache' to force full build.

Sample logs:

Known issue validation

Build: 🔎 https://dev.azure.com/dnceng-public/public/_build/results?buildId=1378681
Error message validated: [Binary log option was specified but MSBuild will be skipped because running just csc is enough]
Result validation: ✅ Known issue matched with the provided build.
Validation performed at: 4/14/2026 9:13:57 PM UTC

Report

Build Definition Test Pull Request
1378978 dotnet/sdk Microsoft.DotNet.Cli.Run.Tests.RunFileTests_BuildCommands.LaunchProfile #53867
1378902 dotnet/sdk Microsoft.DotNet.Cli.Run.Tests.RunFileTests_BuildOptions.WorkingDirectory #53680
1378681 dotnet/sdk Microsoft.DotNet.Cli.Run.Tests.RunFileTests_CscOnlyAndApi.CscOnly #53635

Summary

24-Hour Hit Count 7-Day Hit Count 1-Month Count
3 3 3

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions