Created
June 25, 2017 14:20
-
-
Save rofr/ae40fbe41e3475cd7a977d542314b909 to your computer and use it in GitHub Desktop.
testing assumptions on framework behavior
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
[Fact] | |
public void TryTake_returns_false_when_marked_for_completion() | |
{ | |
var blockingCollection = new BlockingCollection<int>(); | |
blockingCollection.CompleteAdding(); | |
var result = blockingCollection.TryTake(out var item); | |
Assert.False(result); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment