Questions tagged [shouldly]

Shouldly is an assertion framework which focuses on giving great error messages when the assertion fails while being simple and terse.

Resources:

18 questions
0
votes
1 answer

Is there a Resharper pattern for sequential Shouldly asserts?

I'm trying to come up with a Resharper pattern to apply to sequential Shouldly asserts. For instance, I have these checks: field1.ShouldNotBeNull(); field2.ShouldBe(expectedField2Value); And in this case, it should be replaced with: …
0
votes
0 answers

Shouldly LINQ evaluation taking seconds?

We've got an ASP.NET website (Nancy) which uses async/await, and Shouldly for assertions. We're seeing some slow requests (via AppInsights), and the info shows the thread being 'blocked' on ShouldAllBe, specifically the Compile call. Here's an…
RPM1984
  • 72,246
  • 58
  • 225
  • 350
0
votes
1 answer

Unit Tests with Shouldly statement fail

Since some days all my C# unit tests in Visual Studio running on my local machine are raising following TypeInitializationException when reaching the first Shouldly statement: The type initializer for 'Shouldly.ShouldlyConfiguration' threw an…
StefanG
  • 1,234
  • 2
  • 22
  • 46
1
2