Package org.jmock.api

Class ExpectationError

  • All Implemented Interfaces:
    java.io.Serializable, org.hamcrest.SelfDescribing

    public class ExpectationError
    extends java.lang.Error
    implements org.hamcrest.SelfDescribing
    An error thrown when an expectation is violated during a test.
    See Also:
    Serialized Form
    • Constructor Summary

      Constructors 
      Constructor Description
      ExpectationError​(java.lang.String message, org.hamcrest.SelfDescribing expectations, Invocation invocation)  
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void describeTo​(org.hamcrest.Description description)  
      static ExpectationError notAllSatisfied​(org.hamcrest.SelfDescribing expectations)  
      java.lang.String toString()  
      static ExpectationError unexpected​(java.lang.String message, Invocation invocation)  
      • Methods inherited from class java.lang.Throwable

        addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Field Detail

      • expectations

        public final org.hamcrest.SelfDescribing expectations
    • Constructor Detail

      • ExpectationError

        public ExpectationError​(java.lang.String message,
                                org.hamcrest.SelfDescribing expectations,
                                Invocation invocation)
    • Method Detail

      • notAllSatisfied

        public static ExpectationError notAllSatisfied​(org.hamcrest.SelfDescribing expectations)
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Throwable
      • describeTo

        public void describeTo​(org.hamcrest.Description description)
        Specified by:
        describeTo in interface org.hamcrest.SelfDescribing