Skip to content

CodeQL injectes -p:UserSharedCompilation=false into dotnet test causing a failure #12

@PavelBansky

Description

@PavelBansky

When using sandwich mode, CodeQL is injecting -p:UserSharedCompilation=false into dotnet test command, even if the build is not required.

Repro steps:
dotnet test PrimeService.Tests.dll will fail in sandwich mode with error:
The argument -p:UseSharedComilation=false is invalid. Please use the /help option to check the list of valid arguments.

Easy repro steps without CodeQL:
dotnet test PrimeService.Tests.dll -p:UseSharedComilation=false
This will end with the same error
The argument -p:UseSharedComilation=false is invalid. Please use the /help option to check the list of valid arguments.

CodeQL needs to be more sensitive when injecting into dotnet test

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions