Series: Series

11 posts in this series

  1. Series
    December 14, 2022

    ASP.NET Core MVC treats non-nullable properties as implicitly [Required], but calling the validator yourself doesn't. Adjust your unit tests to match.

  2. Series
    December 12, 2022

    AssertConfigurationIsValid skips ReverseMap configurations in AutoMapper. Fix it with two distinct mappings or ValidateMemberList, and know when to use each.

  3. Series
    October 03, 2022

    C# structs can skip your constructor through default values, so preconditions you enforce there may never run. Here's why structs and classes behave …

  4. Series
    September 23, 2022

    Enhance the readability of your tests by customizing Fluent Assertions to your use cases!

  5. Series
    September 13, 2022

    AutoMapper lets you map a type to itself without creating a map, but it returns the same instance instead of a copy. Here's how to force a real copy and test …

  6. Series
    September 06, 2022

    Thinking in relational tables leads to awkward wrapper entities in DDD models. A modeling kata shows why a document database can be a better fit for DDD …

  7. Series
    August 23, 2022

    C# has no built-in string repeat function. Compare four ways to repeat a string N times, with LINQ, StringBuilder, arrays, and Span, plus benchmark results.

  8. Series
    August 23, 2022

    How to make sure you are comparing apples to apples when benchmarking in .NET

  9. Series
    August 23, 2022

    Convert Results from one type to another using the new Map extension method!

  10. Series
    August 18, 2022

    Set up a .NET benchmarking project from scratch with BenchmarkDotNet, using its attributes and APIs to compare the performance of string concatenation methods.