Examples of BadPostException


Examples of tifauv.jplop.core.board.BadPostException

  /**
   * Test method for {@link tifauv.jplop.core.board.BadPostException#BadPostException(java.lang.String)}.
   */
  public void testBadPostExceptionString() {
    // Check without message
    Exception e = new BadPostException(null);
    assertNull(e.getMessage());

    // Check with a message
    e = new BadPostException("plop pikaron");
    assertEquals("plop pikaron", e.getMessage());
  }
View Full Code Here

Examples of tifauv.jplop.core.board.BadPostException

  /**
   * Test method for {@link tifauv.jplop.core.board.BadPostException#BadPostException(java.lang.String, java.lang.Throwable)}.
   */
  public void testBadPostExceptionStringThrowable() {
    // Check without message and cause
    Exception e = new BadPostException(null, null);
    assertNull(e.getMessage());
    assertNull(e.getCause());

    // Check with a message only
    e = new BadPostException("plop pikaron", null);
    assertEquals("plop pikaron", e.getMessage());
    assertNull(e.getCause());

    // Check with a cause only
    Exception cause = new Exception();
    e = new BadPostException(null, cause);
    assertNull(e.getMessage());
    assertEquals(cause, e.getCause());

    // Check with a message only
    e = new BadPostException("plop pikaron", cause);
    assertEquals("plop pikaron", e.getMessage());
    assertEquals(cause, e.getCause());
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.