Tags give the ability to mark specific points in history as being important
-
-
-
-
5.0.1
protectedRelease: 5.0.17457b253 · ·Undo all nullability changes done for version 5.0.0. If you've upgraded to 5.0.0 already, you can simply undo your changes. Sorry! ## Changes * Remove nullability annotations for reference types
-
5.0.0
protectedRelease: 5.0.0d8eaa3b1 · ·# Changes - Enable nullability annotations for the whole package - `error`-parameter of `IAsserter<>.Check` is now `[NotNullWhen(false)] out ValidationError? error` * The attribute is part of the signature - if you implement that interface, you gotta add the attribute as well - `IsNotNull`-assertions are allowed for both nullable reference types and nullable value types * Most other validations are only allowed for non-nullable types, though - which can cause warnings since `IsNotNull` is not changing the asserted type (as it is not required to break on the first error) * To circumvent the "Hey it can be null even though you probably break on the IsNotNull-assertion"-warnings, you can use the following pattern: ```csharp Validator.Check() .That(myValue).IsNotNull() .That(myValue!).IsNotEmpty(); ```
-
4.2.0
protectedRelease: 4.2.0bf9da877 · ·## Changes - Add overload for `IAssertable<string>.Matches()` accepting a `Regex` directly - Add new assertion `IAssertable<string>.IsNotOnlyWhitespace`
-
4.1.1
protectedRelease: 4.1.1100f9976 · ·## Changes - Fix `IsLessThan` and `IsLessThanOrEqual` extensions to produce the correct error message * It falsely claimed "Foo must be greater than 1, but was 2." before - not it will correclty producte "Foo must be less than 1, but was 2."
-
4.1.0
protectedRelease: 4.1.05497ec25 · ·- Add assertion-overloads for all `DateTime` (like `IsAfter` or `IsUtc`) and comparison assertions (`IsLessThan`, `IsGreaterThan`, `IsInRange` and others) - These assertions will *always* fail for null values, except `IsNotEqualTo` - which will always pass for null values
-
4.0.0
protectedRelease: 4.0.0b48d79bb · ·- Name of asserted value is now determined via `CallerArgumentExpression`-Attribute for overloads of `That()` accepting `T` and `Func<T>` (thanks Marco for that hint!) - When accepting a `Func<T>`, the `() =>`-part is removed from the displayed name - The name can still be overriden by passing a name explicitly - Overload of `That()` accepting an `Expression<Func<T>>` has been removed - `Validator.Check()` no longer returns a `Validator` directly but an `IValidation` instead - Extensions to the fluent grammar of `IValidation` have been moved from `Swallow.Validation.Core` to `Swallow.Validation.Assertions` - The namespace is still `Swallow.Validation` - Affected are overloads of `That`, `When`, `Unless`, `Satisfies` as well as `Then`, `Else` and `ElseThrow` - `ValidationContainer` has been moved from `Swallow.Validation.Core` to `Swallow.Validation.Assertions` - The namespace is still `Swallow.Validation` - Collection extensions (`IsNotEmpty`, `IsIn`, `IsNotIn`, `HasAll`, `HasAllValid`) have been moved from `Swallow.Validation.Assertions.Collections` to `Swallow.Validation.Assertions` - DateTime extensions (`IsBefore`, `IsAfter`, `IsBetween`, `isUtc`, `IsLocalTime`) have been moved from `Swallow.Validation.Assertions.DateTime` to `Swallow.Validation.Assertions` - Object extensions (`IsType`, `IsAssignableTo`) have been moved from `Swallow.Validation.Assertions.Types` to `Swallow.Validation.Assertions` - Validatable entity extensions (`IsValid`) have been moved from `Swallow.Validation.Assertions.Validatable` to `Swallow.Validation.Assertions` If you've only referenced `Swallow.Validation.Core` in your projects, you might need to start referencing `Swallow.Validation` instead - which includes both Core and `Swallow.Validation.Assertions`. If you're already referencing `Swallow.Validation`, you'll only need to adjust your usings. And you can finally drop all the `nameof()`s in your `That()`-calls, yay!
-
-
3.1.0
protectedRelease: 3.1.0fef0da38 · ·Tired of providing an `INamedValueProvider` when calling `IAsserter`s yourself? Boy do I have a release for you.. something I should've done since I've done that change. # Changes * Adds new extensions for `IAsserter<>.Check` allowing you to call the method using either only a value or a value and a string as name for that value.
-
3.0.0
protectedRelease: 3.0.0013a2334 · ·* The `Swallow.Validation` package only contains the assertions extending `Swallow.Validation.Core` plus a package reference to `Swallow.Validation.Core` * A separate package for `Swallow.Validation.Core` is published, containing *only* the core * `Swallow.Validation.ServiceCollection` will now be version-locked to `Swallow.Validation.Core`
-
2.0.0
protectedRelease: 2.0.00178a8cd · ·# Breaking Changes - `IAsserter<TValue>`s `Check` method no longer accepts a `TValue` directly, but instead takes in an `INamedValueProvider<TValue>` - This affects the `ValidationContainer` as well! - `SimpleAsserter<TValue>`s `Validate` is now `protected` instead of `public` # Changes - When validating a list of values using `HasAll`, inner errors are now indented using two spaces and contain the name of the asserted value plus the index instead of just the index ([#28])
-
-
1.4.0
protectedRelease: 1.4.0f4f93736 · ·Assertions to check types - for when the type system just isn't enough.
-
1.3.0
protectedRelease: 1.3.09f638a1e · ·Simple asserters, including documentation and a tiny fix for validation exceptions.
-
1.2.0
protectedRelease: 1.2.08e2843ce · ·Validation container 2.0 and collection element assertions
-
-
-
1.0.0
protectedRelease: 1.0.080aea7a9 · ·1.0.0 Release Namespaces have changed, some stuff is internal, but no functional changes have happened since the last prerelease. Still, I have finished all tasks from the 1.0 milestone and I feel confident enough to release Swallow.Validation fully. Basically all extensions and errors have different namespaces now, so prepare for a lotta red when migrating.