Java Code Examples for org.hamcrest.Matchers#anything()
The following examples show how to use
org.hamcrest.Matchers#anything() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: VisibleTextTest.java From darcy-ui with GNU General Public License v3.0 | 5 votes |
@Test public void shouldNotMatchNotVisibleElements() { VisibleText<Text> matcher = new VisibleText<>(Matchers.anything()); Text mockText = mock(Text.class); when(mockText.isDisplayed()).thenReturn(false); assertFalse(matcher.matches(mockText)); }
Example 2
Source File: VisibleTextTest.java From darcy-ui with GNU General Public License v3.0 | 5 votes |
@Test public void shouldMatchVisibleElements() { VisibleText<Text> matcher = new VisibleText<>(Matchers.anything()); Text mockText = mock(Text.class); when(mockText.isDisplayed()).thenReturn(true); assertTrue(matcher.matches(mockText)); }
Example 3
Source File: WindowMatchers.java From beam with Apache License 2.0 | 5 votes |
public static <T> Matcher<WindowedValue<? extends T>> isWindowedValue( Matcher<? super T> valueMatcher, Matcher<? super Instant> timestampMatcher, Matcher<? super Collection<? extends BoundedWindow>> windowsMatcher) { return new WindowedValueMatcher<>( valueMatcher, timestampMatcher, windowsMatcher, Matchers.anything()); }
Example 4
Source File: WindowMatchers.java From beam with Apache License 2.0 | 5 votes |
public static <T> Matcher<WindowedValue<? extends T>> isSingleWindowedValue( Matcher<? super T> valueMatcher, Matcher<? super Instant> timestampMatcher, Matcher<? super BoundedWindow> windowMatcher) { return new WindowedValueMatcher<>( valueMatcher, timestampMatcher, Matchers.contains(windowMatcher), Matchers.anything()); }
Example 5
Source File: WindowMatchers.java From beam with Apache License 2.0 | 4 votes |
public static <T> Matcher<WindowedValue<? extends T>> isWindowedValue( Matcher<? super T> valueMatcher, Matcher<? super Instant> timestampMatcher) { return new WindowedValueMatcher<>( valueMatcher, timestampMatcher, Matchers.anything(), Matchers.anything()); }
Example 6
Source File: StreamRecordMatchers.java From flink with Apache License 2.0 | 4 votes |
public static <T, W extends Window> Matcher<StreamRecord<? extends WindowedValue<? extends T, ? extends W>>> isWindowedValue( Matcher<? super T> valueMatcher, Matcher<? super Long> timestampMatcher) { return new WindowedValueMatcher<>(valueMatcher, timestampMatcher, Matchers.anything()); }
Example 7
Source File: StreamRecordMatchers.java From flink with Apache License 2.0 | 4 votes |
public static <T, W extends Window> Matcher<StreamRecord<? extends WindowedValue<? extends T, ? extends W>>> isWindowedValue( Matcher<? super T> valueMatcher) { return new WindowedValueMatcher<>(valueMatcher, Matchers.anything(), Matchers.anything()); }
Example 8
Source File: StreamRecordMatchers.java From flink with Apache License 2.0 | 4 votes |
public static <T, W extends Window> Matcher<StreamRecord<? extends WindowedValue<? extends T, ? extends W>>> isWindowedValue( Matcher<? super T> valueMatcher, long timestamp) { return new WindowedValueMatcher<>(valueMatcher, Matchers.equalTo(timestamp), Matchers.anything()); }
Example 9
Source File: StreamRecordMatchers.java From flink with Apache License 2.0 | 4 votes |
public static <T> Matcher<StreamRecord<? extends T>> streamRecord( Matcher<? super T> valueMatcher) { return new StreamRecordMatcher<>(valueMatcher, Matchers.anything()); }
Example 10
Source File: SpoonScreenshotAction.java From espresso-cucumber with Apache License 2.0 | 4 votes |
@Override public Matcher<View> getConstraints() { return Matchers.anything(); }
Example 11
Source File: WindowMatchers.java From beam with Apache License 2.0 | 4 votes |
public static <T> Matcher<WindowedValue<? extends T>> isWindowedValue( Matcher<? super T> valueMatcher) { return new WindowedValueMatcher<>( valueMatcher, Matchers.anything(), Matchers.anything(), Matchers.anything()); }
Example 12
Source File: StreamRecordMatchers.java From Flink-CEPplus with Apache License 2.0 | 4 votes |
public static <T> Matcher<StreamRecord<? extends T>> isStreamRecord( Matcher<? super T> valueMatcher) { return new StreamRecordMatcher<>(valueMatcher, Matchers.anything()); }
Example 13
Source File: StreamRecordMatchers.java From flink with Apache License 2.0 | 4 votes |
public static <T, W extends Window> Matcher<StreamRecord<? extends WindowedValue<? extends T, ? extends W>>> isWindowedValue( Matcher<? super T> valueMatcher, Matcher<? super Long> timestampMatcher) { return new WindowedValueMatcher<>(valueMatcher, timestampMatcher, Matchers.anything()); }
Example 14
Source File: StreamRecordMatchers.java From flink with Apache License 2.0 | 4 votes |
public static <T, W extends Window> Matcher<StreamRecord<? extends WindowedValue<? extends T, ? extends W>>> isWindowedValue( Matcher<? super T> valueMatcher) { return new WindowedValueMatcher<>(valueMatcher, Matchers.anything(), Matchers.anything()); }
Example 15
Source File: StreamRecordMatchers.java From flink with Apache License 2.0 | 4 votes |
public static <T, W extends Window> Matcher<StreamRecord<? extends WindowedValue<? extends T, ? extends W>>> isWindowedValue( Matcher<? super T> valueMatcher, long timestamp) { return new WindowedValueMatcher<>(valueMatcher, Matchers.equalTo(timestamp), Matchers.anything()); }
Example 16
Source File: StreamRecordMatchers.java From flink with Apache License 2.0 | 4 votes |
public static <T> Matcher<StreamRecord<? extends T>> isStreamRecord( Matcher<? super T> valueMatcher) { return new StreamRecordMatcher<>(valueMatcher, Matchers.anything()); }
Example 17
Source File: StreamRecordMatchers.java From Flink-CEPplus with Apache License 2.0 | 4 votes |
public static <T, W extends Window> Matcher<StreamRecord<? extends WindowedValue<? extends T, ? extends W>>> isWindowedValue( Matcher<? super T> valueMatcher, Matcher<? super Long> timestampMatcher) { return new WindowedValueMatcher<>(valueMatcher, timestampMatcher, Matchers.anything()); }
Example 18
Source File: StreamRecordMatchers.java From Flink-CEPplus with Apache License 2.0 | 4 votes |
public static <T, W extends Window> Matcher<StreamRecord<? extends WindowedValue<? extends T, ? extends W>>> isWindowedValue( Matcher<? super T> valueMatcher) { return new WindowedValueMatcher<>(valueMatcher, Matchers.anything(), Matchers.anything()); }
Example 19
Source File: StreamRecordMatchers.java From Flink-CEPplus with Apache License 2.0 | 4 votes |
public static <T, W extends Window> Matcher<StreamRecord<? extends WindowedValue<? extends T, ? extends W>>> isWindowedValue( Matcher<? super T> valueMatcher, long timestamp) { return new WindowedValueMatcher<>(valueMatcher, Matchers.equalTo(timestamp), Matchers.anything()); }