Interface GenericIterableAssert<T,U extends java.lang.Iterable<? extends T>,V extends GenericIterableAssert<T,U,V>>
-
- Type Parameters:
T
- the typeU
- the iterable typeV
- the generic iterable assert type
- All Superinterfaces:
EnumerableAssert<U,V>
,GenericObjectAssert<U,V>
- All Known Subinterfaces:
GenericListAssert<T,U,V>
,IterableAssert<T>
,ListAssert<T>
- All Known Implementing Classes:
AbstractIterableAssert
,AbstractListAssert
public interface GenericIterableAssert<T,U extends java.lang.Iterable<? extends T>,V extends GenericIterableAssert<T,U,V>> extends EnumerableAssert<U,V>
Generic iterable assertions.- Since:
- 1.0
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description V
contains(T... values)
Verifies that the iterable contains the given values, in any order.V
containsAll(java.lang.Iterable<? extends T> iterable)
Verifies that the iterable contains all the elements of the given iterable, in any order.V
containsAnyElementsOf(java.lang.Iterable<? extends T> iterable)
Verifies that the iterable contains any of the elements of the given iterable.V
containsAnyOf(T... values)
Verifies that the iterable contains any of the given values.V
containsExactly(T... values)
Verifies that the iterable contains exactly all the given values.V
containsExactlyElementsOf(java.lang.Iterable<? extends T> iterable)
Verifies that the iterable contains exactly the elements of the given iterable.V
containsExactlyInAnyOrder(T... values)
Verifies that the iterable contains exactly all the given values, in any order.V
containsExactlyInAnyOrderElementsOf(java.lang.Iterable<? extends T> values)
Verifies that the iterable contains exactly all of the elements of the given iterable, in any order.V
containsNull()
Verifies that the iterable contains at least one null element.V
containsOnly(T... values)
Verifies that the iterable only contains the given values.V
containsOnlyElementsOf(java.lang.Iterable<? extends T> iterable)
Verifies that the iterable only contains the elements of the given iterable.V
containsOnlyNulls()
Verifies that the iterable only contains null element.V
containsOnlyOnce(T... values)
Verifies that the iterable only contains the given values once.V
containsSequence(java.lang.Iterable<? extends T> sequence)
Verifies that the iterable contains the sequence of the given iterable.V
containsSequence(T... sequence)
Verifies that the iterable contains the given sequence.V
containsSubsequence(java.lang.Iterable<? extends T> subsequence)
Verifies that the iterable contains the subsequence of the given iterable.V
containsSubsequence(T... subsequence)
Verifies that the iterable contains the given subsequence.V
doesNotContain(T... values)
Verifies that the iterable does not contain the given values.V
doesNotContainAnyElementsOf(java.lang.Iterable<? extends T> iterable)
Verifies that the iterable does not contain any of the elements of the given iterable.V
doesNotContainNull()
Verifies that the iterable does not contain any null element.V
doesNotContainSequence(java.lang.Iterable<? extends T> sequence)
Verifies that the iterable does not contain the sequence of the given iterable.V
doesNotContainSequence(T... sequence)
Verifies that the iterable does not contain the given sequence.V
doesNotContainSubsequence(java.lang.Iterable<? extends T> subsequence)
Verifies that the iterable does not contain the subsequence of the given iterable.V
doesNotContainSubsequence(T... subsequence)
Verifies that the iterable does not contain the given subsequence.V
doesNotHaveAnyElementsOfTypes(java.lang.Class<?>... types)
Verifies that the iterable does not have any elements of the given types.V
doesNotHaveDuplicates()
Verifies that the iterable does not have duplicates.V
endsWith(T... sequence)
Verifies that the iterable ends with the given sequence.V
hasAtLeastOneElementOfType(java.lang.Class<?> type)
Verifies that the iterable has at least one element of the given type.V
hasOnlyElementsOfType(java.lang.Class<?> type)
Verifies that the iterable has only elements of the given type.V
hasOnlyElementsOfTypes(java.lang.Class<?>... types)
Verifies that the iterable has only elements of the given types.V
hasSameElementsAs(java.lang.Iterable<? extends T> iterable)
Verifies that the iterable has same elements as the given iterable.V
isSubsetOf(java.lang.Iterable<? extends T> iterable)
Verifies that the iterable is a subset of the given iterable.V
isSubsetOf(T... values)
Verifies that the iterable is a subset of the given values.V
startsWith(T... sequence)
Verifies that the iterable starts with the given sequence.-
Methods inherited from interface io.github.henryssondaniel.teacup.core.assertion.EnumerableAssert
hasSameSizeAs, hasSameSizeAs, hasSize, isEmpty, isNotEmpty, isNullOrEmpty
-
Methods inherited from interface io.github.henryssondaniel.teacup.core.assertion.GenericObjectAssert
doesNotHaveSameClassAs, hasSameClassAs, isEqualTo, isNotEqualTo, isNotSameAs, isSameAs, verify
-
-
-
-
Method Detail
-
contains
V contains(T... values)
Verifies that the iterable contains the given values, in any order.- Parameters:
values
- the values- Returns:
- the iterable assert
- Since:
- 1.0
-
containsAll
V containsAll(java.lang.Iterable<? extends T> iterable)
Verifies that the iterable contains all the elements of the given iterable, in any order.- Parameters:
iterable
- the iterable- Returns:
- the iterable assert
- Since:
- 1.0
-
containsAnyElementsOf
V containsAnyElementsOf(java.lang.Iterable<? extends T> iterable)
Verifies that the iterable contains any of the elements of the given iterable.- Parameters:
iterable
- the iterable- Returns:
- the iterable assert
- Since:
- 1.0
-
containsAnyOf
V containsAnyOf(T... values)
Verifies that the iterable contains any of the given values.- Parameters:
values
- the value- Returns:
- the iterable assert
- Since:
- 1.0
-
containsExactly
V containsExactly(T... values)
Verifies that the iterable contains exactly all the given values.- Parameters:
values
- the values- Returns:
- the iterable assert
- Since:
- 1.0
-
containsExactlyElementsOf
V containsExactlyElementsOf(java.lang.Iterable<? extends T> iterable)
Verifies that the iterable contains exactly the elements of the given iterable.- Parameters:
iterable
- the iterable- Returns:
- the iterable assert
- Since:
- 1.0
-
containsExactlyInAnyOrder
V containsExactlyInAnyOrder(T... values)
Verifies that the iterable contains exactly all the given values, in any order.- Parameters:
values
- the values- Returns:
- the iterable assert
- Since:
- 1.0
-
containsExactlyInAnyOrderElementsOf
V containsExactlyInAnyOrderElementsOf(java.lang.Iterable<? extends T> values)
Verifies that the iterable contains exactly all of the elements of the given iterable, in any order.- Parameters:
values
- the values- Returns:
- the iterable assert
- Since:
- 1.0
-
containsNull
V containsNull()
Verifies that the iterable contains at least one null element.- Returns:
- the iterable assert
- Since:
- 1.0
-
containsOnly
V containsOnly(T... values)
Verifies that the iterable only contains the given values.- Parameters:
values
- the values- Returns:
- the iterable assert
- Since:
- 1.0
-
containsOnlyElementsOf
V containsOnlyElementsOf(java.lang.Iterable<? extends T> iterable)
Verifies that the iterable only contains the elements of the given iterable.- Parameters:
iterable
- the iterable- Returns:
- the iterable assert
- Since:
- 1.0
-
containsOnlyNulls
V containsOnlyNulls()
Verifies that the iterable only contains null element.- Returns:
- the iterable assert
- Since:
- 1.0
-
containsOnlyOnce
V containsOnlyOnce(T... values)
Verifies that the iterable only contains the given values once.- Parameters:
values
- the values- Returns:
- the iterable assert
- Since:
- 1.0
-
containsSequence
V containsSequence(T... sequence)
Verifies that the iterable contains the given sequence.- Parameters:
sequence
- the sequence- Returns:
- the iterable assert
- Since:
- 1.0
-
containsSequence
V containsSequence(java.lang.Iterable<? extends T> sequence)
Verifies that the iterable contains the sequence of the given iterable.- Parameters:
sequence
- the sequence- Returns:
- the iterable assert
- Since:
- 1.0
-
containsSubsequence
V containsSubsequence(T... subsequence)
Verifies that the iterable contains the given subsequence.- Parameters:
subsequence
- the subsequence- Returns:
- the iterable assert
- Since:
- 1.0
-
containsSubsequence
V containsSubsequence(java.lang.Iterable<? extends T> subsequence)
Verifies that the iterable contains the subsequence of the given iterable.- Parameters:
subsequence
- the subsequence- Returns:
- the iterable assert
- Since:
- 1.0
-
doesNotContain
V doesNotContain(T... values)
Verifies that the iterable does not contain the given values.- Parameters:
values
- the values- Returns:
- the iterable assert
- Since:
- 1.0
-
doesNotContainAnyElementsOf
V doesNotContainAnyElementsOf(java.lang.Iterable<? extends T> iterable)
Verifies that the iterable does not contain any of the elements of the given iterable.- Parameters:
iterable
- the iterable- Returns:
- the iterable assert
- Since:
- 1.0
-
doesNotContainNull
V doesNotContainNull()
Verifies that the iterable does not contain any null element.- Returns:
- the iterable assert
- Since:
- 1.0
-
doesNotContainSequence
V doesNotContainSequence(T... sequence)
Verifies that the iterable does not contain the given sequence.- Parameters:
sequence
- the sequence- Returns:
- the iterable assert
- Since:
- 1.0
-
doesNotContainSequence
V doesNotContainSequence(java.lang.Iterable<? extends T> sequence)
Verifies that the iterable does not contain the sequence of the given iterable.- Parameters:
sequence
- the sequence- Returns:
- the iterable assert
- Since:
- 1.0
-
doesNotContainSubsequence
V doesNotContainSubsequence(T... subsequence)
Verifies that the iterable does not contain the given subsequence.- Parameters:
subsequence
- the subsequence- Returns:
- the iterable assert
- Since:
- 1.0
-
doesNotContainSubsequence
V doesNotContainSubsequence(java.lang.Iterable<? extends T> subsequence)
Verifies that the iterable does not contain the subsequence of the given iterable.- Parameters:
subsequence
- the subsequence- Returns:
- the iterable assert
- Since:
- 1.0
-
doesNotHaveAnyElementsOfTypes
V doesNotHaveAnyElementsOfTypes(java.lang.Class<?>... types)
Verifies that the iterable does not have any elements of the given types.- Parameters:
types
- the types- Returns:
- the iterable assert
- Since:
- 1.0
-
doesNotHaveDuplicates
V doesNotHaveDuplicates()
Verifies that the iterable does not have duplicates.- Returns:
- the iterable assert
- Since:
- 1.0
-
endsWith
V endsWith(T... sequence)
Verifies that the iterable ends with the given sequence.- Parameters:
sequence
- the sequence- Returns:
- the iterable assert
- Since:
- 1.0
-
hasAtLeastOneElementOfType
V hasAtLeastOneElementOfType(java.lang.Class<?> type)
Verifies that the iterable has at least one element of the given type.- Parameters:
type
- the type- Returns:
- the iterable assert
- Since:
- 1.0
-
hasOnlyElementsOfType
V hasOnlyElementsOfType(java.lang.Class<?> type)
Verifies that the iterable has only elements of the given type.- Parameters:
type
- type- Returns:
- the iterable assert
- Since:
- 1.0
-
hasOnlyElementsOfTypes
V hasOnlyElementsOfTypes(java.lang.Class<?>... types)
Verifies that the iterable has only elements of the given types.- Parameters:
types
- the types- Returns:
- the iterable assert
- Since:
- 1.0
-
hasSameElementsAs
V hasSameElementsAs(java.lang.Iterable<? extends T> iterable)
Verifies that the iterable has same elements as the given iterable.- Parameters:
iterable
- the iterable- Returns:
- the iterable assert
- Since:
- 1.0
-
isSubsetOf
V isSubsetOf(T... values)
Verifies that the iterable is a subset of the given values.- Parameters:
values
- the values- Returns:
- the iterable assert
- Since:
- 1.0
-
isSubsetOf
V isSubsetOf(java.lang.Iterable<? extends T> iterable)
Verifies that the iterable is a subset of the given iterable.- Parameters:
iterable
- the iterable- Returns:
- the iterable assert
- Since:
- 1.0
-
-