Skip to content

Cancelling tests in MTP might produce exception that is hard to interpret by users #51519

@Youssef1313

Description

@Youssef1313

When cancelling, we might end up hitting this:

if (_handler.HasMismatchingTestSessionEventCount())
{
throw new InvalidOperationException(CliCommandStrings.MissingTestSessionEnd);
}

We got a test session start, but no corresponding test session end, so we consider it a protocol violation.

  • Should MTP still send test session finish when cancellation is requested?
  • If not:
    • Should we only consider showing this exception if the exit code of the process is success? or probably anything other than aborted?
    • If we go that way, what about --ignore-exit-code?

Metadata

Metadata

Assignees

No one assigned

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions