Class MetricAssertions.GaugeAssert<T>

java.lang.Object
org.assertj.core.api.AbstractAssert<MetricAssertions.GaugeAssert<T>,org.apache.flink.metrics.Gauge<T>>
org.apache.flink.metrics.testutils.MetricAssertions.GaugeAssert<T>
All Implemented Interfaces:
org.assertj.core.api.Assert<MetricAssertions.GaugeAssert<T>,org.apache.flink.metrics.Gauge<T>>, org.assertj.core.api.Descriptable<MetricAssertions.GaugeAssert<T>>, org.assertj.core.api.ExtensionPoints<MetricAssertions.GaugeAssert<T>,org.apache.flink.metrics.Gauge<T>>
Enclosing class:
MetricAssertions

public static class MetricAssertions.GaugeAssert<T> extends org.assertj.core.api.AbstractAssert<MetricAssertions.GaugeAssert<T>,org.apache.flink.metrics.Gauge<T>>
This class provides AssertJ assertions for Gauges.
  • Field Summary

    Fields inherited from class org.assertj.core.api.AbstractAssert

    actual, info, myself, objects, throwUnsupportedExceptionOnEquals
  • Method Summary

    Modifier and Type
    Method
    Description
    isCloseTo(long value, long epsilon)
    Verifies that the gauges value is close to the expected value within a certain deviation.
    isEqualTo(Object expected)
    Verifies that the gauges value is equal to the expected one.

    Methods inherited from class org.assertj.core.api.AbstractAssert

    areEqual, asInstanceOf, asList, assertionError, asString, describedAs, descriptionText, doesNotHave, doesNotHaveSameClassAs, doesNotHaveSameHashCodeAs, doesNotHaveToString, equals, extracting, extracting, failure, failureWithActualExpected, failWithActualExpectedAndMessage, failWithMessage, getWritableAssertionInfo, has, hashCode, hasSameClassAs, hasSameHashCodeAs, hasToString, inBinary, inHexadecimal, is, isElementOfCustomAssert, isExactlyInstanceOf, isIn, isIn, isInstanceOf, isInstanceOfAny, isInstanceOfSatisfying, isNot, isNotEqualTo, isNotExactlyInstanceOf, isNotIn, isNotIn, isNotInstanceOf, isNotInstanceOfAny, isNotNull, isNotOfAnyClassIn, isNotSameAs, isNull, isOfAnyClassIn, isSameAs, matches, matches, newListAssertInstance, overridingErrorMessage, overridingErrorMessage, satisfies, satisfies, satisfies, satisfiesAnyOf, satisfiesAnyOf, satisfiesAnyOfForProxy, satisfiesForProxy, setCustomRepresentation, setDescriptionConsumer, setPrintAssertionsDescription, throwAssertionError, usingComparator, usingComparator, usingDefaultComparator, usingRecursiveComparison, usingRecursiveComparison, withFailMessage, withFailMessage, withRepresentation, withThreadDumpOnError

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface org.assertj.core.api.Descriptable

    as, as, as, describedAs
  • Method Details

    • isEqualTo

      public MetricAssertions.GaugeAssert<T> isEqualTo(Object expected)
      Verifies that the gauges value is equal to the expected one.
      Specified by:
      isEqualTo in interface org.assertj.core.api.Assert<MetricAssertions.GaugeAssert<T>,org.apache.flink.metrics.Gauge<T>>
      Overrides:
      isEqualTo in class org.assertj.core.api.AbstractAssert<MetricAssertions.GaugeAssert<T>,org.apache.flink.metrics.Gauge<T>>
      Parameters:
      expected - the given value to compare the actual value to.
      Returns:
      this assertion object
    • isCloseTo

      public MetricAssertions.GaugeAssert<T> isCloseTo(long value, long epsilon)
      Verifies that the gauges value is close to the expected value within a certain deviation.
      Parameters:
      value - the expected value
      epsilon - the maximum deviation from the expected value
      Returns:
      this assertion object