Skip to content

Add FSI options tests#19346

Draft
bbatsov wants to merge 1 commit intodotnet:mainfrom
bbatsov:add-fsi-options-tests
Draft

Add FSI options tests#19346
bbatsov wants to merge 1 commit intodotnet:mainfrom
bbatsov:add-fsi-options-tests

Conversation

@bbatsov
Copy link
Copy Markdown
Contributor

@bbatsov bbatsov commented Feb 22, 2026

Description

Adds test coverage for FSI-specific command-line options that previously had none. This includes --quiet, --exec, --use, --load, --gui, --readline, --quotations-debug, --shadowcopyreferences, --nologo, and error cases for unknown options and invalid --warn levels.

Also wires up the existing but never-compiled CLI test files (FsiCliTests.fs, FscCliTests.fs, CliProcessTests.fs) by adding them to the .fsproj and implementing the runFsiProcess/runFscProcess subprocess helpers they depend on.

Contributes to #13878

Checklist

  • Test cases added

  • Performance benchmarks added in case of performance changes

  • Release notes entry updated:

    If you believe that release notes are not necessary for this PR, please add NO_RELEASE_NOTES label to the pull request.

@github-actions
Copy link
Copy Markdown
Contributor

✅ No release notes required

@bbatsov bbatsov mentioned this pull request Feb 22, 2026
3 tasks
Add runFsiProcess/runFscProcess subprocess helpers to Compiler.fs and
include the existing CLI test files (FsiCliTests.fs, FscCliTests.fs,
CliProcessTests.fs) in the project build.

Add 19 new tests covering --quiet, --exec, --use, --load, --gui,
--readline, --quotations-debug, --shadowcopyreferences, --nologo,
and error cases for unknown options and invalid --warn levels.

Contributes to dotnet#13878
@bbatsov bbatsov force-pushed the add-fsi-options-tests branch from dc1a4fe to 67e228e Compare March 5, 2026 10:39
@T-Gro T-Gro marked this pull request as draft March 6, 2026 18:26
@github-project-automation github-project-automation bot moved this from New to In Progress in F# Compiler and Tooling Apr 10, 2026
/// Expected: //<Expects id="FS0225" status="error">Source file ['"].+['"] could not be found</Expects>
/// CLI Test: FSC with non-existent absolute path (Windows-style)
[<FactForWINDOWS>]
[<FactForDESKTOP>]
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

The rest of the PR is good, but this is suspicious - this drops coverage for testing of .NETCore (like net10) on Windows, and only moves to testing via .NET Framework.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: In Progress

Development

Successfully merging this pull request may close these issues.

2 participants