-
Notifications
You must be signed in to change notification settings - Fork 324
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cancel/abort not honored when sent before custom host launch #1543
Merged
Merged
Changes from 11 commits
Commits
Show all changes
20 commits
Select commit
Hold shift + click to select a range
1f41e27
Initial commit
abhishkk 1b09512
Cancellation in custom host launcher, test host, while ongoing commun…
abhishkk 60b74d8
passing cancellation to data collectors.
abhishkk 51bcc10
build issues fix
abhishkk c3dc452
review comments
abhishkk 7674f35
Unit tests
abhishkk eb079c6
Merge branch 'master' into cancelNotHonored
abhishkk 046c86a
review comments
abhishkk e206964
resolve conflict
abhishkk 653047a
Merge branch 'master' into cancelNotHonored
abhishkk 3015b3e
Passing operation canceled instead of test platform exception to tran…
abhishkk 4513b14
review comments
abhishkk 3a77114
review comments
abhishkk 07f8abd
review comments
abhishkk b11ac54
review comments
abhishkk 145ef38
Merge branch 'master' into cancelNotHonored
abhishkk 93923a2
unit tests fix
abhishkk 10fa006
Merge branch 'cancelNotHonored' of https://github.com/abhishkk/vstest…
abhishkk 24bd933
unit tests fail
abhishkk 08975c6
unit tests
abhishkk File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,6 +5,7 @@ namespace Microsoft.VisualStudio.TestPlatform.CommunicationUtilities.Interfaces | |
{ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Threading; | ||
|
||
using Microsoft.VisualStudio.TestPlatform.CommunicationUtilities.ObjectModel; | ||
using Microsoft.VisualStudio.TestPlatform.ObjectModel.Client; | ||
|
@@ -29,8 +30,9 @@ public interface ITestRequestSender : IDisposable | |
/// Waits for Request Handler to be connected | ||
/// </summary> | ||
/// <param name="connectionTimeout">Time to wait for connection</param> | ||
/// <param name="cancellationToken">Cancellation token</param> | ||
/// <returns>True, if Handler is connected</returns> | ||
bool WaitForRequestHandlerConnection(int connectionTimeout); | ||
bool WaitForRequestHandlerConnection(int connectionTimeout, CancellationToken cancellationToken); | ||
|
||
/// <summary> | ||
/// Close the Sender | ||
|
@@ -61,14 +63,16 @@ public interface ITestRequestSender : IDisposable | |
/// </summary> | ||
/// <param name="runCriteria">RunCriteria for test run</param> | ||
/// <param name="eventHandler">EventHandler for test run events</param> | ||
void StartTestRun(TestRunCriteriaWithSources runCriteria, ITestRunEventsHandler eventHandler); | ||
/// <param name="cancellationToken">Cancellation token</param> | ||
void StartTestRun(TestRunCriteriaWithSources runCriteria, ITestRunEventsHandler eventHandler, CancellationToken cancellationToken); | ||
|
||
/// <summary> | ||
/// Starts the TestRun with given test cases and criteria | ||
/// </summary> | ||
/// <param name="runCriteria">RunCriteria for test run</param> | ||
/// <param name="eventHandler">EventHandler for test run events</param> | ||
void StartTestRun(TestRunCriteriaWithTests runCriteria, ITestRunEventsHandler eventHandler); | ||
/// <param name="cancellationToken">Cancellation token</param> | ||
void StartTestRun(TestRunCriteriaWithTests runCriteria, ITestRunEventsHandler eventHandler, CancellationToken cancellationToken); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
same question.. is this a public interface ? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Done. Modified existing methods. |
||
|
||
/// <summary> | ||
/// Ends the Session | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
won't we fail to receive data (testruncomplete )
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In case of cancellation and abort, we dont get any attachments from data collectors and simply cancels the run. So adding isCancelled will do the same thing. For non-cancelled run, we will be able to successfully able to receive data