New Post: Floating point precision
Hi, It's there, but I've refactored some of the numeric assertion methods. The BeApproximately is now an extension method on NumericAssertions<T>. Check out the following changeset:...
View ArticleCreated Issue: Please update documentation how to use extension methods to...
In the documentation, there is Verification.Fail("Expected whatever..."); used to fail the test. I assume that is is now done with Execute.Verification or Execute.Fail.Could you please update the...
View ArticleUpdated Wiki: Documentation
Supported Test Frameworks Fluent Assertions supports MSTest, NUnit and XUnit. Starting with version 1.3.0, you can simply add a reference to the corresponding test framework assembly to the unit test...
View ArticleCommented Issue: Please update documentation how to use extension methods to...
In the documentation, there is Verification.Fail("Expected whatever..."); used to fail the test. I assume that is is now done with Execute.Verification or Execute.Fail.Could you please update the...
View ArticleNew Post: Initial Setup
Just for those like me that started to use Fluent Assertions. Add the reference to Fluent Assertions in your test project and add "using FluentAssertions;" at the top of your test file
View ArticleNew Post: Initial Setup
...in case you're not using an advanced tool like ReSharper or DevExpress :-)
View ArticleUpdated Wiki: Temporary Post Used For Theme Detection...
This is a temporary post that was not deleted. Please delete this manually. (15ce7833-df31-4055-8ee5-eae2f0b8f366 - 3bfe001a-32de-4114-a6b4-4005b770f6d7)
View ArticleUpdated Wiki: Home
Project Description Fluent Assertions is a set of .NET extension methods that allow you to more naturally specify the expected outcome of a TDD or BDD-style test. We currently use it in all our...
View ArticleClosed Issue: Better readability with extension methods on int [10087]
Include Minutes(), Hours() and Days() extension methods on integers, for better readability of DateTime assertions.For example:public static TimeSpan Minutes(this int source){ return...
View ArticleNew Post: myString.Should().Contain("abc") ignoring case
Hi! What would be the best syntax to check for string containing another string ignoring case? I see a couple of options: myString.Should().Contain("abc", StringComparison.OrdinalIgnoreCase); or...
View ArticleNew Post: The name BeEquivalentTo() is misleading for strings
Hi! The name of string assertion BeEquivalentTo looks misleading to me. For collection assertions it means "contains same elements regardless of order". For strings equivalence means case-insensitive...
View ArticleNew Post: Method proposal: str.Should().BeBlank()
Hi! I find quite useful to check that string is/is not blank (i.e. null, empty or whitespace-only). Out of 800+ tests in my current project 18 use NotBeBlank and 3 use BeBlank. I think it would be a...
View ArticleNew Post: Method proposal: str.Should().BeBlank()
Don't you think it will be confusing to have a BeEmpty (count of chars == 0) and BeBlank()? Additionaly, I do think an empty string is something different than a null-string. In my projects, returning...
View ArticleNew Post: The name BeEquivalentTo() is misleading for strings
I agree with your statement that names of members should give a clear understanding. However, I never consider a string to be a collection of characters. I don't want to introduce breaking changes, but...
View ArticleNew Post: myString.Should().Contain("abc") ignoring case
Continuing the 'equivalence' convention, I would say: myString.Should().ContainEquivalentOf("abc");
View ArticleClosed Feature: Resolve name of event in ShouldRaise using lambda expression...
It would be more helpfull if the name of an event that should be raised could be deteremined using a lambda expression. Like: theClass.ShouldRaise(() => c.Event); This makes it easier for...
View Article