Class SerializableMatchers

java.lang.Object
org.apache.beam.sdk.testing.SerializableMatchers
All Implemented Interfaces:
Serializable

public class SerializableMatchers extends Object implements Serializable
Static class for building and using SerializableMatcher instances.

Most matchers are wrappers for hamcrest's Matchers. Please be familiar with the documentation there. Values retained by a SerializableMatcher are required to be serializable, either via Java serialization or via a provided Coder.

The following matchers are novel to Apache Beam:

For example, to match a group from GroupByKey, which has type KV<K, Iterable<V>> for some K and V and where the order of the iterable is undefined, use a matcher like kv(equalTo("some key"), containsInAnyOrder(1, 2, 3)).

See Also: