Anatomy of an expectation
Every expectation starts with Expect.That(subject), continues with what you expect and is awaited:
Negation
Almost every expectation has a negated counterpart that starts with IsNot… or DoesNot…, e.g. IsNotEqualTo,
Combining expectations
Expectations can be combined on the same subject, on its members or on different subjects:
null subjects
A null subject fails an expectation and its negation, unless the expectation is about null:
Options
Many expectations share the same options. An option is appended to the expectation it configures, and the reference
Time and cancellation
Some expectations take time: they await a task or an asynchronous delegate, enumerate an IAsyncEnumerable, wait
Configuration
You can customize certain behavior or specify default values to use globally.
Native AOT and trimming
Publishing with trimming or Native AOT removes code and metadata that is only reached through reflection. aweXpect