I'm pretty new to unit testing and currently experimenting a bit with Visual Studio's testing tools.
My question is how to define assertions about concurrent behaviour in these tests. E.g. given a class BoundedChan<T> implementing a bounded channel, how can I specify tests like
- "
channel.Sendwill not block" or - "If the channel's capacity is exceeded,
channel.Sendwill block until a value is read"
Is there an elegant solution to write these assertions?