Skip to content

Conversation

@wfurt
Copy link
Member

@wfurt wfurt commented Dec 3, 2019

Improve test to make sure we actually do renegotiation.
It is curious that we actually never set _pendingReHandshake to true in production code.

I will address it as part of #453

@wfurt wfurt self-assigned this Dec 3, 2019
@wfurt
Copy link
Member Author

wfurt commented Dec 3, 2019

/azp run runtime-libraries outerloop

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@wfurt wfurt requested review from a team and stephentoub December 3, 2019 05:46
@wfurt
Copy link
Member Author

wfurt commented Dec 3, 2019

Outerloop test failures are unrelated. Updated renegotiate tests passed.

Copy link
Member

@eiriktsarpalis eiriktsarpalis left a comment

Choose a reason for hiding this comment

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

LGTM 👍

// There's no good way to ensure renegotiation happened in the test.
// Under the debugger, we can see this test hits the renegotiation codepath.
// Renegotiation will trigger another validation callback/
Assert.True(validationCount > 1);
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
Assert.True(validationCount > 1);
Assert.InRange(validationCount, 2, int.MaxValue);

// There's no good way to ensure renegotiation happened in the test.
// Under the debugger, we can see this test hits the renegotiation codepath.
// renegotiation will trigger validation callback again.
Assert.True(validationCount > 1);
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
Assert.True(validationCount > 1);
Assert.InRange(validationCount, 2, int.MaxValue);

@davidsh davidsh added this to the 5.0 milestone Dec 3, 2019
@wfurt wfurt merged commit dd003e7 into dotnet:master Dec 3, 2019
@wfurt wfurt deleted the ssl_renego branch December 3, 2019 18:24
@ghost ghost locked as resolved and limited conversation to collaborators Dec 11, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants