Class HmRsTextBody

  • All Implemented Interfaces:
    org.hamcrest.Matcher<Response>, org.hamcrest.SelfDescribing

    public final class HmRsTextBody
    extends AbstractHmTextBody<Response>
    Response text body matcher.

    This "matcher" tests given response body, assuming that it has text content.

    The class is immutable and thread-safe.

    Since:
    2.0
    • Constructor Detail

      • HmRsTextBody

        public HmRsTextBody​(String expected)
        Ctor with equalTo matcher and default charset.
        Parameters:
        expected - String to test against
      • HmRsTextBody

        public HmRsTextBody​(org.hamcrest.Matcher<String> bdm)
        Ctor with charset set to default one.
        Parameters:
        bdm - Text body matcher
      • HmRsTextBody

        public HmRsTextBody​(org.hamcrest.Matcher<String> bdm,
                            Charset charset)
        Ctor.
        Parameters:
        bdm - Text body matcher
        charset - Text body charset