Table of Contents

Class AllException

Namespace
Xunit.Sdk
Assembly
xunit.v3.assert.dll

Exception thrown when Assert.All fails.

public class AllException : XunitException, ISerializable, IAssertionException
Inheritance
AllException
Implements
Inherited Members

Methods

ForFailures(int, IReadOnlyList<Tuple<int, string, Exception>>)

Creates a new instance of the AllException class to be thrown when one or more items failed during Assert.All<T>(IEnumerable<T>, Action<T>) or Assert.All<T>(IEnumerable<T>, Action<T, int>), Assert.AllAsync<T>(IEnumerable<T>, Func<T, Task>), or Assert.AllAsync<T>(IEnumerable<T>, Func<T, int, Task>).

public static AllException ForFailures(int totalItems, IReadOnlyList<Tuple<int, string, Exception>> errors)

Parameters

totalItems int

The total number of items in the collection

errors IReadOnlyList<Tuple<int, string, Exception>>

The list of failures (as index, value, and exception)

Returns

AllException