Extension packages
Expectations for types outside the base class library are provided by separate packages. Each package adds extension
methods on IThat<T> for its types, so once it is referenced, its expectations appear on That(…) next to the
built-in ones.
Core extensions
These packages live in the aweXpect repository and are released together with aweXpect, always with the same version.
| Package | Checks |
|---|---|
| aweXpect.Json | JSON strings, JsonElement, JsonNode and the serialization of objects |
| aweXpect.Reflection | assemblies, types and members, for architecture and convention tests |
| aweXpect.Snapshots | strings, objects and public APIs against a reviewed snapshot |
| aweXpect.Web | HttpRequestMessage, HttpResponseMessage, Uri and IPAddress |
| aweXpect.Xml | XML strings, XElement and XDocument |
Separate extensions
These packages have their own repository and release cycle.
| Package | Version | Checks |
|---|---|---|
| aweXpect.Logging | 0.3.0 | the records of a FakeLogger or FakeLogCollector |
| aweXpect.Mockolate | 4.0.0 | interactions with Mockolate mocks |
| aweXpect.Testably | 3.0.0 | the file and time systems of Testably.Abstractions |
aweXpect.Chronology adds readable TimeSpan and DateTime values like 5.Seconds() or 24.December(2024). It adds no expectations and does not depend on aweXpect; many samples in this documentation use it.
Write your own
If no package covers your types, you can add expectations yourself with the same API these packages use. Extending aweXpect walks you through your first expectation and the conventions for its failure messages.