FsCheck


Default

Namespace: FsCheck
Parent Module: Arb
Attributes:
[<AbstractClass>]
[<Sealed>]

Static members

Static memberDescription
Default.Array()
Signature: unit -> Arbitrary<'a []>
Type parameters: 'a

Generate a rank 1 array.

Default.Array2D()
Signature: unit -> Arbitrary<'?202346 [,]>
Type parameters: '?202346

Generate a rank 2, zero based array.

Default.Arrow()
Signature: unit -> Arbitrary<('a -> 'b)>
Type parameters: 'a, 'b

Generate a function value. Function values can be generated for types 'a->'b where 'b has an Arbitrary instance. There is no shrinking for function values.

Default.BigInt()
Signature: unit -> Arbitrary<bigint>

Arbitray instance for BigInteger.

Default.Bool()
Signature: unit -> Arbitrary<bool>

Generates an arbitrary bool.

Default.Byte()
Signature: unit -> Arbitrary<byte>

Generates an arbitrary byte.

Default.Char()
Signature: unit -> Arbitrary<char>

Generates arbitrary chars, between ASCII codes Char.MinValue and 127.

Default.Culture()
Signature: unit -> Arbitrary<CultureInfo>
Default.DateTime()
Signature: unit -> Arbitrary<DateTime>

Generates an arbitrary DateTime between 1900 and 2100. A DateTime is shrunk by removing its Kind, millisecond, second, minute and hour components.

Default.DateTimeOffset()
Signature: unit -> Arbitrary<DateTimeOffset>

Generates an arbitrary DateTimeOffset between 1900 and 2100. A DateTimeOffset is shrunk first by shrinking its offset, then by removing its second, minute and hour components.

Default.Decimal()
Signature: unit -> Arbitrary<Decimal>

Generate arbitrary decimal.

Default.Derive()
Signature: unit -> Arbitrary<'a>
Type parameters: 'a

Try to derive an arbitrary instance for the given type reflectively. Generates and shrinks values for record, union, tuple and enum types. Also generates (but doesn't shrink) values for basic classes (i.e. either classes having a single constructor with immutable values
or DTO classes with a default constructor and public property setters).

Default.Dictionary()
Signature: unit -> Arbitrary<Dictionary<'?202420,'?202421>>
Type parameters: '?202420, '?202421

Generate a System.Collections.Generic.Dictionary of values. Shrinks by reducing the number of elements

Default.DoNotShrink()
Signature: unit -> Arbitrary<DoNotShrink<'?202436>>
Type parameters: '?202436

Overrides the shrinker of any type to be empty, i.e. not to shrink at all.

Default.DoNotSizeDateTime()
Signature: unit -> Arbitrary<DoNotSize<DateTime>>

Generate arbitrary DateTime that is unrestricted by size. A DateTime is shrunk by removing its Kind, millisecond, second, minute and hour components.

Default.DoNotSizeInt16()
Signature: unit -> Arbitrary<DoNotSize<int16>>

Generate arbitrary int16 that is uniformly distributed in the whole range of int16 values.

Default.DoNotSizeInt32()
Signature: unit -> Arbitrary<DoNotSize<int>>

Generate arbitrary int32 that is unrestricted by size.

Default.DoNotSizeInt64()
Signature: unit -> Arbitrary<DoNotSize<int64>>

Generate arbitrary int64 that is unrestricted by size.

Default.DoNotSizeUInt16()
Signature: unit -> Arbitrary<DoNotSize<uint16>>

Generate arbitrary uint16 that is uniformly distributed in the whole range of uint16 values.

Default.DoNotSizeUInt32()
Signature: unit -> Arbitrary<DoNotSize<uint32>>

Generate arbitrary uint32 that is unrestricted by size.

Default.DoNotSizeUInt64()
Signature: unit -> Arbitrary<DoNotSize<uint64>>

Generate arbitrary uint64 that is unrestricted by size.

Default.DontShrink()
Signature: unit -> Arbitrary<DoNotShrink<'?202434>>
Type parameters: '?202434 Attributes:
[<Obsolete("Renamed to DoNotShrink.")>]
WARNING: This API is obsolete

Renamed to DoNotShrink.

Overrides the shrinker of any type to be empty, i.e. not to shrink at all.

Default.DontSizeInt16()
Signature: unit -> Arbitrary<DoNotSize<int16>>
Attributes:
[<Obsolete("Renamed to DoNotSizeInt16.")>]
WARNING: This API is obsolete

Renamed to DoNotSizeInt16.

Generate arbitrary int16 that is uniformly distributed in the whole range of int16 values.

Default.DontSizeInt32()
Signature: unit -> Arbitrary<DoNotSize<int>>
Attributes:
[<Obsolete("Renamed to DoNotSizeInt32.")>]
WARNING: This API is obsolete

Renamed to DoNotSizeInt32.

Generate arbitrary int32 that is unrestricted by size.

Default.DontSizeInt64()
Signature: unit -> Arbitrary<DoNotSize<int64>>
Attributes:
[<Obsolete("Renamed to DoNotSizeInt64.")>]
WARNING: This API is obsolete

Renamed to DoNotSizeInt64.

Generate arbitrary int64 that is unrestricted by size.

Default.DontSizeUInt16()
Signature: unit -> Arbitrary<DoNotSize<uint16>>
Attributes:
[<Obsolete("Renamed to DoNotSizeUInt16.")>]
WARNING: This API is obsolete

Renamed to DoNotSizeUInt16.

Generate arbitrary uint16 that is uniformly distributed in the whole range of uint16 values.

Default.DontSizeUInt32()
Signature: unit -> Arbitrary<DoNotSize<uint32>>
Attributes:
[<Obsolete("Renamed to DoNotSizeUInt32.")>]
WARNING: This API is obsolete

Renamed to DoNotSizeUInt32.

Generate arbitrary uint32 that is unrestricted by size.

Default.DontSizeUInt64()
Signature: unit -> Arbitrary<DoNotSize<uint64>>
Attributes:
[<Obsolete("Renamed to DoNotSizeUInt64.")>]
WARNING: This API is obsolete

Renamed to DoNotSizeUInt64.

Generate arbitrary uint64 that is unrestricted by size.

Default.FixedLengthArray()
Signature: unit -> Arbitrary<FixedLengthArray<'a>>
Type parameters: 'a

Arrays whose length does not change when shrinking.

Default.Float()
Signature: unit -> Arbitrary<double>

Generates arbitrary 64 bit floats, NaN, NegativeInfinity, PositiveInfinity, Maxvalue, MinValue, Epsilon included fairly frequently.

Default.Float32()
Signature: unit -> Arbitrary<float32>

Generates arbitrary 32 bit floats, NaN, NegativeInfinity, PositiveInfinity, Maxvalue, MinValue, Epsilon included fairly frequently.

Default.FsList()
Signature: unit -> Arbitrary<'a list>
Type parameters: 'a

Generate a list of values. The size of the list is between 0 and the test size + 1.

Default.Fun()
Signature: unit -> Arbitrary<('?202351 -> '?202352)>
Type parameters: '?202351, '?202352 Attributes:
[<CompiledName("FSharpFun")>]

Generate a F# function value. Function values can be generated for types 'a->'b where 'b has an Arbitrary instance. There is no shrinking for function values.

CompiledName: FSharpFun

Default.Function()
Signature: unit -> Arbitrary<Function<'a,'b>>
Type parameters: 'a, 'b

Generate a Function value that can be printed and shrunk. Function values can be generated for types 'a->'b where 'b has an Arbitrary instance.

Default.Guid()
Signature: unit -> Arbitrary<Guid>
Default.HostName()
Signature: unit -> Arbitrary<HostName>
Default.ICollection()
Signature: unit -> Arbitrary<ICollection<'?202418>>
Type parameters: '?202418

Generate a System.Collections.Generic.ICollection of values.

Default.IDictionary()
Signature: unit -> Arbitrary<IDictionary<'?202423,'?202424>>
Type parameters: '?202423, '?202424

Generate a System.Collections.Generic.IDictionary of values. Shrinks by reducing the number of elements

Default.IList()
Signature: unit -> Arbitrary<IList<'?202416>>
Type parameters: '?202416

Generate a System.Collections.Generic.IList of values.

Default.Int16()
Signature: unit -> Arbitrary<int16>

Generate arbitrary int16 that is between -size and size.

Default.Int32()
Signature: unit -> Arbitrary<int>

Generate arbitrary int32 that is between -size and size.

Default.Int64()
Signature: unit -> Arbitrary<int64>

Generate arbitrary int64 that is between -size and size. Note that since the size is an int32, this does not actually cover the full range of int64. See DoNotSize instead.

Default.Interval()
Signature: unit -> Arbitrary<Interval>

Generates an interval between two non-negative integers.

Default.IntWithMinMax()
Signature: unit -> Arbitrary<IntWithMinMax>
Default.IPAddress()
Signature: unit -> Arbitrary<IPAddress>
Default.IPv4Address()
Signature: unit -> Arbitrary<IPv4Address>
Default.IPv6Address()
Signature: unit -> Arbitrary<IPv6Address>
Default.KeyValuePair()
Signature: unit -> Arbitrary<KeyValuePair<'?202391,'?202392>>
Type parameters: '?202391, '?202392
Default.List()
Signature: unit -> Arbitrary<List<'?202414>>
Type parameters: '?202414

Generate a System.Collections.Generic.List of values.

Default.MailAddress()
Signature: unit -> Arbitrary<MailAddress>
Default.Map()
Signature: unit -> Arbitrary<Map<'?202405,'?202406>>
Type parameters: '?202405, '?202406
Default.NegativeInt()
Signature: unit -> Arbitrary<NegativeInt>
Default.NonEmptyArray()
Signature: unit -> Arbitrary<NonEmptyArray<'?202408>>
Type parameters: '?202408
Default.NonEmptySet()
Signature: unit -> Arbitrary<NonEmptySet<'?202410>>
Type parameters: '?202410
Default.NonEmptyString()
Signature: unit -> Arbitrary<NonEmptyString>
Default.NonNegativeInt()
Signature: unit -> Arbitrary<NonNegativeInt>
Default.NonNull()
Signature: unit -> Arbitrary<NonNull<'a>>
Type parameters: 'a

Generate underlying values that are not null.

Default.NonZeroInt()
Signature: unit -> Arbitrary<NonZeroInt>
Default.NormalFloat()
Signature: unit -> Arbitrary<NormalFloat>

Generates a "normal" 64 bit floats (without NaN, Infinity, Epsilon, MinValue, MaxValue)

Default.Nullable()
Signature: unit -> Arbitrary<Nullable<'a>>
Type parameters: 'a

Generate a nullable value that is null 1/8 of the time.

Default.Object()
Signature: unit -> Arbitrary<obj>

Generate an object - a boxed char, string or boolean value.

Default.Option()
Signature: unit -> Arbitrary<'a option>
Type parameters: 'a

Generate an option value that is 'None' 1/8 of the time.

Default.PositiveInt()
Signature: unit -> Arbitrary<PositiveInt>
Default.SByte()
Signature: unit -> Arbitrary<sbyte>

Generates an arbitrary signed byte.

Default.Set()
Signature: unit -> Arbitrary<Set<'?202403>>
Type parameters: '?202403
Default.String()
Signature: unit -> Arbitrary<String>

Generates arbitrary strings, which are lists of chars generated by Char.

Default.StringWithoutNullChars()
Signature: unit -> Arbitrary<StringNoNulls>
Default.SystemAction()
Signature: unit -> Arbitrary<Action>

Generates an Action'0

Default.SystemAction1()
Signature: unit -> Arbitrary<Action<'?202378>>
Type parameters: '?202378

Generates an Action'1

Default.SystemAction2()
Signature: unit -> Arbitrary<Action<'?202380,'?202381>>
Type parameters: '?202380, '?202381

Generates an Action'2

Default.SystemAction3()
Signature: unit -> Arbitrary<Action<'?202383,'?202384,'?202385>>
Type parameters: '?202383, '?202384, '?202385

Generates an Action'3

Default.SystemFunc()
Signature: unit -> Arbitrary<Func<'?202363>>
Type parameters: '?202363

Generates a Func'1.

Default.SystemFunc1()
Signature: unit -> Arbitrary<Func<'?202365,'?202366>>
Type parameters: '?202365, '?202366

Generates a Func'2.

Default.SystemFunc2()
Signature: unit -> Arbitrary<Func<'?202368,'?202369,'?202370>>
Type parameters: '?202368, '?202369, '?202370

Generates a Func'3.

Default.SystemFunc3()
Signature: unit -> Arbitrary<Func<'?202372,'?202373,'?202374,'?202375>>
Type parameters: '?202372, '?202373, '?202374, '?202375

Generates a Func'4.

Default.ThrowingFunction()
Signature: unit -> Arbitrary<ThrowingFunction<'?202357,'?202358>>
Type parameters: '?202357, '?202358 Attributes:
[<CompiledName("ThrowingFSharpFun")>]

Generate an F# function value that generates an instance of the function result type about half the time. The other times it generates one of a list of common .NET exceptions, including Exception, ArgumentException, ArithmeticException, IOException, NotImplementedException, OUtOfMemoryException and others.

CompiledName: ThrowingFSharpFun

Default.ThrowingFunction(exceptions)
Signature: exceptions:seq<Exception> -> Arbitrary<ThrowingFunction<'a,'b>>
Type parameters: 'a, 'b Attributes:
[<CompiledName("ThrowingFSharpFun")>]

Generate am F# function value that generates an instance of the function result type about half the time. The other times it generates one of the given exceptions.

CompiledName: ThrowingFSharpFun

Default.TimeSpan()
Signature: unit -> Arbitrary<TimeSpan>

Generates an arbitrary TimeSpan. A TimeSpan is shrunk by removing days, hours, minutes, second and milliseconds.

Default.UInt16()
Signature: unit -> Arbitrary<uint16>

Generate arbitrary uint16 that is between 0 and size.

Default.UInt32()
Signature: unit -> Arbitrary<uint32>

Generate arbitrary uint32 that is between 0 and size.

Default.UInt64()
Signature: unit -> Arbitrary<uint64>

Generate arbitrary uint64 that is between 0 and size.

Default.Unit()
Signature: unit -> Arbitrary<unit>

Generates (), of the unit type.

Default.XmlEncodedString()
Signature: unit -> Arbitrary<XmlEncodedString>
Fork me on GitHub