Module org.testfx

Class AbstractLabeledAssert<SELF extends AbstractLabeledAssert<SELF>>

  • All Implemented Interfaces:
    org.assertj.core.api.Assert<SELF,​javafx.css.Styleable>, org.assertj.core.api.Descriptable<SELF>, org.assertj.core.api.ExtensionPoints<SELF,​javafx.css.Styleable>
    Direct Known Subclasses:
    AbstractButtonAssert, LabeledAssert

    public class AbstractLabeledAssert<SELF extends AbstractLabeledAssert<SELF>>
    extends AbstractParentAssert<SELF>
    Base class for all Labeled assertions.
    • Constructor Detail

      • AbstractLabeledAssert

        protected AbstractLabeledAssert​(javafx.scene.control.Labeled actual,
                                        Class<?> selfType)
    • Method Detail

      • hasText

        public SELF hasText​(String text)
        Verifies that the actual Labeled has exactly the given text.
        Parameters:
        text - the given text to compare the actual text to
        Returns:
        this assertion object
      • doesNotHaveText

        public SELF doesNotHaveText​(String text)
        Verifies that the actual Labeled does not have exactly the given text.
        Parameters:
        text - the given text to compare the actual text to
        Returns:
        this assertion object
      • hasText

        public SELF hasText​(org.hamcrest.Matcher<String> matcher)
        Verifies that the actual Labeled is matched by the given matcher.
        Parameters:
        matcher - the String matcher to test the actual text with
        Returns:
        this assertion object
      • doesNotHaveText

        public SELF doesNotHaveText​(org.hamcrest.Matcher<String> matcher)
        Verifies that the actual Labeled is not matched by the given matcher.
        Parameters:
        matcher - the String matcher to test the actual text with
        Returns:
        this assertion object