Interface AttributeAssert<T>

    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      T hasAttribute​(String attribute)
      Checks if the element, or at least one element in a list of elements, has the given property.
      org.assertj.core.api.AbstractAssert hasNotAttribute​(String attribute)
      Checks if the element doesn't have, or no element in a list of elements has, the given property.
    • Method Detail

      • hasAttribute

        T hasAttribute​(String attribute)
        Checks if the element, or at least one element in a list of elements, has the given property.

        It allows users to do not just presence validation but to apply chained assertions to further validate the attribute values.

        Parameters:
        attribute - the attribute to find
        Returns:
        a new assert object with the actual attribute value
      • hasNotAttribute

        org.assertj.core.api.AbstractAssert hasNotAttribute​(String attribute)
        Checks if the element doesn't have, or no element in a list of elements has, the given property.
        Parameters:
        attribute - attribute to find the absence of
        Returns:
        this assertion object.