Examples of AssertedFailure


Examples of com.github.jmkgreen.morphia.testutil.AssertedFailure

  }
 
 
  @Test
  public void testDuplicatedPropertyName() throws Exception {
    new AssertedFailure(ConstraintViolationException.class) {
      public void thisMustFail() throws Throwable {
        morphia.map(DuplicatedPropertyName.class);
      }
    };
    new AssertedFailure(ConstraintViolationException.class) {
      public void thisMustFail() throws Throwable {
        morphia.map(DuplicatedPropertyName2.class);
      }
    };
    new AssertedFailure(ConstraintViolationException.class) {
      public void thisMustFail() throws Throwable {
        morphia.map(Extends.class);
      }
    };
  }
View Full Code Here

Examples of com.github.jmkgreen.morphia.testutil.AssertedFailure

    long hubba;
  }
 
  @Test
  public void testCheck() {
    new AssertedFailure(ConstraintViolationException.class) {
      public void thisMustFail() throws Throwable {
        morphia.map(Fail1.class);
      }
    };
    new AssertedFailure(ConstraintViolationException.class) {
      public void thisMustFail() throws Throwable {
        morphia.map(Fail2.class);
      }
    };
    morphia.map(OK1.class);
View Full Code Here

Examples of com.github.jmkgreen.morphia.testutil.AssertedFailure

 
  @Test
  public void testCheck() {
    morphia.map(MapWithWrongKeyType1.class);
   
    new AssertedFailure() {
      public void thisMustFail() throws Throwable {
        morphia.map(MapWithWrongKeyType2.class);
      }
    };
   
    new AssertedFailure() {
      public void thisMustFail() throws Throwable {
        morphia.map(MapWithWrongKeyType3.class);
      }
    };
  }
View Full Code Here

Examples of com.github.jmkgreen.morphia.testutil.AssertedFailure

    private static final long serialVersionUID = 1L;
  }
 
  @Test
  public void testCheck() {
    new AssertedFailure(ConstraintViolationException.class) {
      public void thisMustFail() throws Throwable {
        morphia.map(E.class);
      }
     
      @Override
View Full Code Here

Examples of com.github.jmkgreen.morphia.testutil.AssertedFailure

    private static final long serialVersionUID = 1L;
  }
 
  @Test
  public void testLazyRefOnArray() {
    new AssertedFailure(ConstraintViolationException.class) {
     
      @Override
      protected void thisMustFail() throws Throwable {
        morphia.map(LazyOnArray.class);
      }
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.