NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
NuGet
NuGet, #1979 most downloaded on NuGet
FsCheck is a tool for testing .NET programs automatically. You provide a specification of the program, in the form of properties which functions, methods or objects should satisfy, and FsCheck then tests that the properties hold in a large number of randomly generated cases. Such properties are actually a testable specification of your program. Properties are written in F#, C# or VB. FsCheck helps you to define properties, observe the distribution of test data, and define test data generators. Crucially, when a property fails, FsCheck automatically displays a minimal counter example.
Latest stable
3.6.0
Last release 1 months ago
21 Oct 2026
Release timing varies
gaps range from 8 days to 11 months
Most releases are documented
notes for 48 of the last 60 stable releases
5 versions withdrawn
withdrawn after publishing
127 years old
108 releases · first in 1900
Drag across the ruler to compare, or tap a release to open it.
Additionally target netstandard2.1 and net8.0. Added generators and shrinkers for System.Index and System.Range (#621), Memory , ReadOnlyMemory , Read
Additionally target netstandard2.1 and net8.0.
Added generators and shrinkers for System.Index and System.Range (#621), Memory<T>, ReadOnlyMemory<T>, ReadOnlySequence<T>, ValueTask and ValueTask<T> in netstandard2.1.
Added generators and shrinkers for System.Half, Int128, UInt128, DateOnly, TimeOnly and Rune in net8.0.
Added NullableRef<T> to conveniently generate nulls for reference types (#610).
Support NUnit 5 (by Nathan Bierema) Added support for NUnit ValueFormatters. Added Gen.delay to defer generator construction until a value is generate
Support NUnit 5 (by Nathan Bierema)
Added support for NUnit ValueFormatters.
Added Gen.delay to defer generator construction until a value is generated.
Added support for timeout in xUnit v3.
Your coding agent can read these notes before it upgrades. Set up the MCP server →
Updated xunit.v3 to version 4.x. (by Simon Baynes)
Updated xunit.v3 to version 4.x. (by Simon Baynes)
Fixed a bug in C# record type generation.
Fixed a bug in C# record type generation.
Add Gen.pick and Gen.tryPick functions. Fill NullReferenceException when using Replay with an Implies combinator. Improve behavior of stamps and label
Add Gen.pick and Gen.tryPick functions. Fill NullReferenceException when using Replay with an Implies combinator. Improve behavior of stamps and labels when using And/Or property combinators.
Fixed FsCheck.NUnit failure reporting. (by Brian Rourke Boll) Added a replay hint to failure message. (by Brian Rourke Boll)
Fixed FsCheck.NUnit failure reporting. (by Brian Rourke Boll) Added a replay hint to failure message. (by Brian Rourke Boll)
Update xunit.v3.extensibility.core to v3.0.1 to fix a test discovery issue. (by Hyogeol Lee)
Update xunit.v3.extensibility.core to v3.0.1 to fix a test discovery issue. (by Hyogeol Lee)
Added FsCheck.Xunit.v3. (by JohSand)
Added FsCheck.Xunit.v3. (by JohSand)
Support C# struct record generation. (by Brian Rourke Boll) Xunit Property respects IAsyncLifetime. (by Arialdo Martini)
Support C# struct record generation. (by Brian Rourke Boll)
Xunit Property respects IAsyncLifetime. (by Arialdo Martini)
Support Async<'Testable> & Task<'Testable>. Slight behavior change: an explicit upcast to non-generic Task (:> Task) is now needed for tests involving
Support Async<'Testable> & Task<'Testable>. Slight behavior change: an explicit upcast to non-generic Task (:> Task) is now needed for tests involving Task<'T> where 'T is not itself a testable type. (by Brian Rourke Boll)
FsCheck.Xunit: target net462 explicitly, so xunit picks the right runner on .NET Framework.
FsCheck.Xunit: target net462 explicitly, so xunit picks the right runner on .NET Framework.
Fix stamp missing for final test. (by Calum Sieppert) FsCheck.NUnit: updated to NUnit 4. (with David Naylor) FsCheck.NUnit: implement PropertiesAttrib
Fix stamp missing for final test. (by Calum Sieppert) FsCheck.NUnit: updated to NUnit 4. (with David Naylor) FsCheck.NUnit: implement PropertiesAttribute. (by Oleksandr Bogomaz) FsCheck.NUnit: handle NUnit's signalling exceptions. (by Oleksandr Bogomaz) FsCheck.Xunit: fixed MissingMethodException caused by integration issue with xunit 2.9.x.
Breaking change: confusingly named StringNoNnulls is renamed to StringNoNullChar.
StringNoNnulls is renamed to StringNoNullChar.|@, @| and %> are removed. Please use Prop.label instead.ForAll overloads for various Task types.NonEmptySet, NonEmptyArray and FixedLengthArray now implement IEnnumerable to avoid a call to Get in common scenarios.Negative decimals are now also generated. (by Stephen Smith)
Negative decimals are now also generated. (by Stephen Smith)
Relax FsCheck.Xunit's restriction on xUnit versions. (by Tom Rijnbeek)
Made Gen.choose64 public.
Remove dependency on FAKE and paket in favor of standard .NET tools. (by Patrick Stevens)cription of the release
Enable properties that return Task . (by Mark Seemann)
Enable properties that return Task<T>. (by Mark Seemann)
Includes all changes up to 2.16.6.
Fixed bug that caused exceptions not to be propagated to output correctly. Added a few missing methods in Fluent.Arbitrary. Add a few missing Prop.For
Fixed bug that caused exceptions not to be propagated to output correctly.
Added a few missing methods in Fluent.Arbitrary.
Add a few missing Prop.ForAll overloads.
Includes changes in 2.16.4.
Backwards incompatible*: Refactor and split of the Gen and Arbitrary APIs into FsCheck.FSharp and FsCheck.Fluent. This is a first step in splitting th…
Backwards incompatible*: Refactor and split of the Gen and Arbitrary APIs into FsCheck.FSharp and FsCheck.Fluent. This is a first step in splitting the entire API into a functional (for F# consumers) and fluent (for C# and VB.NET consumers) interface. This should be clearer for both kinds of consumers.
By and large, if you are an F# user, now open FsCheck.FSharp in addition to open FsCheck. If you are a C# or VB.NET user, add using FsCheck.Fluent.
Backwards incompatible*: redesigned API for per-type Arbitrary instance discovery and lookup. There is no longer a single global, mutable map of type to Arbitrary instances, instead there are any number of immutable IArbMaps that can be configured at your leisure, and set via Config.WithArbitrary on the test.
Detailed changes to FsCheck.FSharp.Gen: Added RequireQualifiedAccess. Added apply and bind. Renamed collect and sequence to collect/sequenceToList/Array/Seq for clarity. Removed unzip and unzip3 - their implementation is problematic, and it's hard to see a use case for them. Removed subListOfToIlist, subListOfArr - these returned IList<'T> types. Untupled rows,cols arguments in array2DOfDim.
Detailed changes to FsCheck.Fluent.Gen: Split into non-extension methods on Gen and extension methods on Gen<T> type in GenExtensions. Removed Gen.Apply - not useful without partial application. Two, Three, Four and Zip now output ValueTuples, which is idiomatic in modern C#, and are only visible as extension methods on Gen<T>. Removed the overloads of Zip with arity 3. Changed the return type of methods that returned IList<T> previously to List<T>. Split the Sample method with optional arguments in three overloads, this is better for backwards compatibilty going forward.
Detailed changes to FsCheck.FSharp.Arb: Removed fromGenShrinkFunc. Removed register, registerByType, from, generate and shrink - these are replaced by functions on ArbMap, resp. mergeWith, mergeWithType, arbitrary and generate. Made Arb.Default internal. Default types should now be looked up using ArbMap, e.g. ArbMap.defaults |> ArbMap.arbitrary<list<int>>.
Detailed changes to FsCheck.Fluent.Arb: Removed extension method ToArbitrary that took an F# function as argument for the shrinker. Renamad Arb.From methods to Arbitrary.From - C# does not tolerate ambiguity between using two types of the same name in the same namespace. Removed Register, RegisterByType, From, Generate and Shrink - these are replaced by methods on ArbMap, resp. Merge<'T>, Merge, ArbFor and GeneratorFor. Made Arb.Default internal. Default Arbitrary types should now be looked up using ArbMap, e.g. ArbMap.Default.ArbFor<int[]>().
First pass at improving XML docs for Gen API.
Fixed bug in try..with computation expression builder.
Added support for let!...and!... syntax in computation expression builder.
Nothing published for this version
Propagate thread-local arbitraries to thread pool threads that are executing tests.
Propagate thread-local arbitraries to thread pool threads that are executing tests.
NuGet packaging: relax FSharp.Core constraint to 4.0 and higher for .NET Desktop.
NuGet packaging: relax FSharp.Core constraint to 4.0 and higher for .NET Desktop.
Remove PCL builds. NET Standard is the way forward. Latest FSharp.Core builds don't even include PCL versions. As a result of the FSharp.Core dependen
Remove PCL builds. NET Standard is the way forward. Latest FSharp.Core builds don't even include PCL versions. As a result of the FSharp.Core dependency, FsCheck targets NET Standard 1.6. Remove Prop.within. Remove tuple and list testables. Bug fix: Tasks that were faulted or canceled were not detected as test failures (by chrisoverzero)
Update random number generator to SplitMix algorithm. (with thanks to Jack Pappas for making it fast) Add support for parallel and async testing. (by
Update random number generator to SplitMix algorithm. (with thanks to Jack Pappas for making it fast) Add support for parallel and async testing. (by Sergey - great effort!) Simplify sampling data: Gen.sample et al.
Added Map and Return methods to make FsCheck more F#+ friendly. (by Gustavo Leon)
Added Map and Return methods to make FsCheck more F#+ friendly. (by Gustavo Leon)
Improved C# record type generation - previously no values for some properties were not generated.
Improved C# record type generation - previously no values for some properties were not generated.
Fixed display issue affecting custom F# exceptions. Prop.throws now fails the test if an unexpected exception is thrown.
Fixed display issue affecting custom F# exceptions.
Prop.throws now fails the test if an unexpected exception is thrown.
Allow configuration in FsCheck.Xunit.PropertiesAttribute to affect properties on nested types or modules. PropertiesAttribute on the closest enclosing
Allow configuration in FsCheck.Xunit.PropertiesAttribute to affect properties on nested types or modules. PropertiesAttribute on the closest enclosing type takes precedence. Add FsCheck.Xunit.TestOutputRunner - a simple runner which just redirects output to xUnit's TestOutputHelper.
Support generation and shrinking of System.Collections.Immutable types via reflection.
Support generation and shrinking of System.Collections.Immutable types via reflection.
Include inherited methods when registering Arbitrary instances. (by Bennie Copeland)
Include inherited methods when registering Arbitrary instances. (by Bennie Copeland)
Support generating C# record types.
Support generating C# record types.
Allow shrinking private unions. (by Sander van Dijk) Limit total number of shrink attempts to 5000, to avoid infinite loops in general, and in particu
Allow shrinking private unions. (by Sander van Dijk) Limit total number of shrink attempts to 5000, to avoid infinite loops in general, and in particular if an argument is mutated in the test.
Enabled FsCheck.Xunit's PropertiesAttribute to work at assembly level. (by Laurence King) Added UnicodeString and UnicodeChar generators.
Enabled FsCheck.Xunit's PropertiesAttribute to work at assembly level. (by Laurence King)
Added UnicodeString and UnicodeChar generators.
Fixed a bug in FsCheck.Xunit: using ITestOutputHelper did not show output in Property-attributed tests.
Fixed a bug in FsCheck.Xunit: using ITestOutputHelper did not show output in Property-attributed tests.
Updated NUnit to 3.13.1, and set that as the lowest allowable version in FsCheck.NUnit package. Fixed resulting incompatibility. Since NUnit 3.13 no l
Updated NUnit to 3.13.1, and set that as the lowest allowable version in FsCheck.NUnit package. Fixed resulting incompatibility. Since NUnit 3.13 no longer supports netstandard 1.6, removed netstandard 1.6 support from FsCheck.NUnit as well.
Restrict NUnit version range to versions < 3.13.1, as that introduced an incompatibility with FsCheck.NUnit.
Restrict NUnit version range to versions < 3.13.1, as that introduced an incompatibility with FsCheck.NUnit.
Workaround for suspected F# compiler bug: prevented compiler from inlining Prop.discard. (by Okke Hendriks)
Workaround for suspected F# compiler bug: prevented compiler from inlining Prop.discard. (by Okke Hendriks)
Nothing published for this version
Fix FsCheck.Xunit so it properly calls Dispose if the test class implements IDisposable. (by Laurence King)
Fix FsCheck.Xunit so it properly calls Dispose if the test class implements IDisposable. (by Laurence King)
Assembly metadata fix. This caused version 2.14.1 to be unusable in some cases; it was unlisted.
Assembly metadata fix. This caused version 2.14.1 to be unusable in some cases; it was unlisted.
Add support for struct type generation and shrinking. (by Kody Musick) Support setting PropertyAttribute.Replay to null. (by Eirik Tsarpalis)
Add support for struct type generation and shrinking. (by Kody Musick) Support setting PropertyAttribute.Replay to null. (by Eirik Tsarpalis)
Add shrinker for data transfer objects. (by Carlo Zancanaro) Add shrinker for Interval type. (by Nazar Vinnichuk) Add shrinker for flags enums. (by Na
Add shrinker for data transfer objects. (by Carlo Zancanaro) Add shrinker for Interval type. (by Nazar Vinnichuk) Add shrinker for flags enums. (by Nazar Vinnichuk) Add new Arbitrary instances for Numerics.Complex and ConsoleKeyInfo. (by Nazar Vinnichuk) Fix float, int32 and int64 generators so their distribution is uniform. This also improves downstream generators. (by Nazar Vinnichuk) Fix decimal generator so size is respected. (by Nazar Vinnichuk) Add Gen.scale and ScaleSize extension method which can remove some boilerplate. (by Nazar Vinnichuk)
Stop shipping Portable Class Libraries (PCL), which are essentially deprecated by Microsoft in favor of .NET Standard. FsCheck now targets .NET Standa…
Stop shipping Portable Class Libraries (PCL), which are essentially deprecated by Microsoft in favor of .NET Standard. FsCheck now targets .NET Standard 1.0 (which takes the place of 3 PCLs that were previously included, while it still run on all those platforms and more), .NET Standard 1.6 (which is the lowest version modern FSharp.Core versions support) and .NET Standard 2.0 (which is advised by NuGet so clients don't need to download as much stuff if they can target 2.0 or higher). FsCheck also still targets .NET Framework 4.5.2 and upwards as a convenience. FsCheck.Xunit and FsCheck.NUnit similarly target .NET Standard 1.6 and 2.0, as well as .NET Framework 4.5.2. They've never targeted PCL before. It's my hope and expectation that this makes FsCheck usable on the same range of platforms (and more) as before, while greatly simplifying development: there is now just one solution (instead of three), and only one FsCheck project (instead of five) and so on. Add NonWhiteSpaceString to default generated types. (by Stijn Moreels)
Fix FsCheck.Xunit's CheckExtensions so that the throwing methods actually throw on failure. Add new generator extensions for C#: Zip, Zip3, Or and OrN
Fix FsCheck.Xunit's CheckExtensions so that the throwing methods actually throw on failure. Add new generator extensions for C#: Zip, Zip3, Or and OrNull. (by Stijn Moreels) Add Gen.collect and variations. (by Stijn Moreels) Fix to offset of DateTimeOffset generator. (by Evgeny Grebenyuk)
Update NUnit to 3.10.1. Add Arbitrary instance for XML encoded string. (by Stijn Moreels)
Update NUnit to 3.10.1. Add Arbitrary instance for XML encoded string. (by Stijn Moreels)
DateTime now also generates kind and milliseconds (by Matthew Peacock) Removed EditorBrowsable.Never from all but the obsoleted methods. F# intellisen
DateTime now also generates kind and milliseconds (by Matthew Peacock) Removed EditorBrowsable.Never from all but the obsoleted methods. F# intellisense now also honors these attributes, and so they were hiding a bunch of methods unnecessarily. The upshot is that C# users will see more of the API that is F# specific.
Gen.subListOf can now generate the entire given list, where previously it would always generate a strict sublist. (by Michał Niegrzybowski)
Gen.subListOf can now generate the entire given list, where previously it would always generate a strict sublist. (by Michał Niegrzybowski)
FsCheck.NUnit: Bugs fixed and added support for Ignore and Category attributes. (by Eirik Tsarpalis)
FsCheck.NUnit: Bugs fixed and added support for Ignore and Category attributes. (by Eirik Tsarpalis)
Add some C# extension members to combine boolean properties. (by Stijn Moreels)
Add some C# extension members to combine boolean properties. (by Stijn Moreels)
Fix FsCheck.NUnit issue - failure output was not shown. (by adj123) Add C# Implies extension method. (by adj123)
Fix FsCheck.NUnit issue - failure output was not shown. (by adj123) Add C# Implies extension method. (by adj123)
NuGet packaging: relax FSharp.Core constraint to 4.0 and higher for .NET Desktop and PCL targets.
NuGet packaging: relax FSharp.Core constraint to 4.0 and higher for .NET Desktop and PCL targets.
NuGet Packaging updates. (by Enrico Sada) Small performance improvements in Gen.apply and mapN.
NuGet Packaging updates. (by Enrico Sada) Small performance improvements in Gen.apply and mapN.
Change NuGet dependency of FsCheck.Xunit and FsCheck.NUnit on FsCheck to strict equality constraint. Add specific dependency group to nuspec for net45
Change NuGet dependency of FsCheck.Xunit and FsCheck.NUnit on FsCheck to strict equality constraint. Add specific dependency group to nuspec for net45 so that NuGet does not download a bunch of packages needlessly.
Don't escape newline and tab characters.
Don't escape newline and tab characters.
Fix stack overflow in Gen.piles, listOf and arrayOf when generating long collections.
Fix stack overflow in Gen.piles, listOf and arrayOf when generating long collections.
Make Gen.variant thread safe. Allow registration of Arbitrary instances that are defined as properties, in addition to methods. Show control character
Make Gen.variant thread safe. Allow registration of Arbitrary instances that are defined as properties, in addition to methods. Show control characters, which are unprintable, as escaped ascii codes in the output.
Update FsCheck.NUnit to work with NUnit 3.8.1. FsCheck.NUnit is not backwards compatible with earlier NUnit versions because NUnit changed the name of
Update FsCheck.NUnit to work with NUnit 3.8.1. FsCheck.NUnit is not backwards compatible with earlier NUnit versions because NUnit changed the name of a few methods in their extension API.
Gen.listOf and Gen.arrayOf now divide the size among the element generators, to avoid exponential explosion of size when high-dimensional types like int list list list are generated. This is the approach advocated in https://gupea.ub.gu.se/handle/2077/22087. The effect on list and array generators is as follows, quoting from that text: This adjustment of the list generator impacts the distribution in several ways. Most apparently it inverts the correlation between the length of the list and the size of the elements, long lists will tend to have small elements instead of large. Short lists with small elements will be generated whenever n is low. Short lists with large elements will occur when n is large and a small k is chosen. If a large k is chosen instead, long list with small elements will be generated. The only way to generate long lists with large elements is if n is very large, which is natural given that the purpose of the modified algorithm is to reduce the size of test data.
Add Gen.piles generator, which generates a list of random elements that add up to a given sum.
Fix a bug in recursive union type generation that could lead to stack overflow in some cases.
Fix a bug in recursive union type generation that could lead to stack overflow in some cases.
Add NegativeInt type and Arbitrary instance. (by Stijn Moreels) Update SourceLink to v2. (by Cameron Taggart)
Add NegativeInt type and Arbitrary instance. (by Stijn Moreels) Update SourceLink to v2. (by Cameron Taggart)
Add a .NET Standard 1.6 build to FsCheck, FsCheck.NUnit and FsCheck.Xunit NuGet packages. (with Enrico Sada) Update to latest FSharp.Core 4.1. The las
Add a .NET Standard 1.6 build to FsCheck, FsCheck.NUnit and FsCheck.Xunit NuGet packages. (with Enrico Sada) Update to latest FSharp.Core 4.1. The last version to support 3.1 or higher is FsCheck 2.8.2.
Add a .NET Standard 1.6 compatible build to FsCheck, FsCheck.NUnit and FsCheck.Xunit. (with Enrico Sada) Update to latest FSharp.Core 4.1.
Add a .NET Standard 1.6 compatible build to FsCheck, FsCheck.NUnit and FsCheck.Xunit. (with Enrico Sada) Update to latest FSharp.Core 4.1.
Add a .NET Standard 1.6 compatible build to FsCheck, FsCheck.NUnit and FsCheck.Xunit. (with Enrico Sada) Update to latest FSharp.Core 4.1.
Add a .NET Standard 1.6 compatible build to FsCheck, FsCheck.NUnit and FsCheck.Xunit. (with Enrico Sada) Update to latest FSharp.Core 4.1.
One column per quarter.