Examples of excludeUnlistedClasses()


Examples of javax.persistence.spi.PersistenceUnitInfo.excludeUnlistedClasses()

    assertEquals("ormap2.xml", pu1.getMappingFileNames().get(0));

    assertEquals(1, pu1.getJarFileUrls().size());
    assertEquals(new ClassPathResource("order.jar").getURL(), pu1.getJarFileUrls().get(0));

    assertFalse(pu1.excludeUnlistedClasses());

    assertSame(PersistenceUnitTransactionType.RESOURCE_LOCAL, pu1.getTransactionType());

    Properties props = pu1.getProperties();
    assertEquals(2, props.keySet().size());
View Full Code Here

Examples of javax.persistence.spi.PersistenceUnitInfo.excludeUnlistedClasses()

    assertNull(pu1.getNonJtaDataSource());

    assertSame(ds, pu1.getJtaDataSource());

    assertFalse("Exclude unlisted should default false in 1.0.", pu1.excludeUnlistedClasses());

    PersistenceUnitInfo pu2 = info[1];

    assertSame(PersistenceUnitTransactionType.JTA, pu2.getTransactionType());
    assertEquals("com.acme.AcmePersistence", pu2.getPersistenceProviderClassName());
View Full Code Here

Examples of javax.persistence.spi.PersistenceUnitInfo.excludeUnlistedClasses()

    // the following assertions fail only during coverage runs
    // assertEquals(1, pu2.getJarFileUrls().size());
    // assertEquals(new ClassPathResource("order-supplemental.jar").getURL(), pu2.getJarFileUrls().get(0));

    assertTrue(pu2.excludeUnlistedClasses());

    assertNull(pu2.getJtaDataSource());
    assertEquals(ds, pu2.getNonJtaDataSource());

    assertTrue("Exclude unlisted should be true when no value.", pu2.excludeUnlistedClasses());
View Full Code Here

Examples of javax.persistence.spi.PersistenceUnitInfo.excludeUnlistedClasses()

    assertTrue(pu2.excludeUnlistedClasses());

    assertNull(pu2.getJtaDataSource());
    assertEquals(ds, pu2.getNonJtaDataSource());

    assertTrue("Exclude unlisted should be true when no value.", pu2.excludeUnlistedClasses());
  }

  @Test
  public void testExample6() throws Exception {
    PersistenceUnitReader reader = new PersistenceUnitReader(
View Full Code Here

Examples of javax.persistence.spi.PersistenceUnitInfo.excludeUnlistedClasses()

    assertEquals("The number of persistence units is incorrect.", 4, info.length);

    PersistenceUnitInfo noExclude = info[0];
    assertNotNull("noExclude should not be null.", noExclude);
    assertEquals("noExclude name is not correct.", "NoExcludeElement", noExclude.getPersistenceUnitName());
    assertFalse("Exclude unlisted should default false in 1.0.", noExclude.excludeUnlistedClasses());

    PersistenceUnitInfo emptyExclude = info[1];
    assertNotNull("emptyExclude should not be null.", emptyExclude);
    assertEquals("emptyExclude name is not correct.", "EmptyExcludeElement", emptyExclude.getPersistenceUnitName());
    assertTrue("emptyExclude should be true.", emptyExclude.excludeUnlistedClasses());
View Full Code Here

Examples of javax.persistence.spi.PersistenceUnitInfo.excludeUnlistedClasses()

    assertFalse("Exclude unlisted should default false in 1.0.", noExclude.excludeUnlistedClasses());

    PersistenceUnitInfo emptyExclude = info[1];
    assertNotNull("emptyExclude should not be null.", emptyExclude);
    assertEquals("emptyExclude name is not correct.", "EmptyExcludeElement", emptyExclude.getPersistenceUnitName());
    assertTrue("emptyExclude should be true.", emptyExclude.excludeUnlistedClasses());

    PersistenceUnitInfo trueExclude = info[2];
    assertNotNull("trueExclude should not be null.", trueExclude);
    assertEquals("trueExclude name is not correct.", "TrueExcludeElement", trueExclude.getPersistenceUnitName());
    assertTrue("trueExclude should be true.", trueExclude.excludeUnlistedClasses());
View Full Code Here

Examples of javax.persistence.spi.PersistenceUnitInfo.excludeUnlistedClasses()

    assertTrue("emptyExclude should be true.", emptyExclude.excludeUnlistedClasses());

    PersistenceUnitInfo trueExclude = info[2];
    assertNotNull("trueExclude should not be null.", trueExclude);
    assertEquals("trueExclude name is not correct.", "TrueExcludeElement", trueExclude.getPersistenceUnitName());
    assertTrue("trueExclude should be true.", trueExclude.excludeUnlistedClasses());

    PersistenceUnitInfo falseExclude = info[3];
    assertNotNull("falseExclude should not be null.", falseExclude);
    assertEquals("falseExclude name is not correct.", "FalseExcludeElement", falseExclude.getPersistenceUnitName());
    assertFalse("falseExclude should be false.", falseExclude.excludeUnlistedClasses());
View Full Code Here

Examples of javax.persistence.spi.PersistenceUnitInfo.excludeUnlistedClasses()

    assertTrue("trueExclude should be true.", trueExclude.excludeUnlistedClasses());

    PersistenceUnitInfo falseExclude = info[3];
    assertNotNull("falseExclude should not be null.", falseExclude);
    assertEquals("falseExclude name is not correct.", "FalseExcludeElement", falseExclude.getPersistenceUnitName());
    assertFalse("falseExclude should be false.", falseExclude.excludeUnlistedClasses());
  }

  @Test
  public void testJpa2ExcludeUnlisted() throws Exception {
    PersistenceUnitReader reader = new PersistenceUnitReader(
View Full Code Here

Examples of javax.persistence.spi.PersistenceUnitInfo.excludeUnlistedClasses()

    assertFalse("Exclude unlisted still defaults to false in 2.0.", noExclude.excludeUnlistedClasses());

    PersistenceUnitInfo emptyExclude = info[1];
    assertNotNull("emptyExclude should not be null.", emptyExclude);
    assertEquals("emptyExclude name is not correct.", "EmptyExcludeElement", emptyExclude.getPersistenceUnitName());
    assertTrue("emptyExclude should be true.", emptyExclude.excludeUnlistedClasses());

    PersistenceUnitInfo trueExclude = info[2];
    assertNotNull("trueExclude should not be null.", trueExclude);
    assertEquals("trueExclude name is not correct.", "TrueExcludeElement", trueExclude.getPersistenceUnitName());
    assertTrue("trueExclude should be true.", trueExclude.excludeUnlistedClasses());
View Full Code Here

Examples of javax.persistence.spi.PersistenceUnitInfo.excludeUnlistedClasses()

    assertTrue("emptyExclude should be true.", emptyExclude.excludeUnlistedClasses());

    PersistenceUnitInfo trueExclude = info[2];
    assertNotNull("trueExclude should not be null.", trueExclude);
    assertEquals("trueExclude name is not correct.", "TrueExcludeElement", trueExclude.getPersistenceUnitName());
    assertTrue("trueExclude should be true.", trueExclude.excludeUnlistedClasses());

    PersistenceUnitInfo falseExclude = info[3];
    assertNotNull("falseExclude should not be null.", falseExclude);
    assertEquals("falseExclude name is not correct.", "FalseExcludeElement", falseExclude.getPersistenceUnitName());
    assertFalse("falseExclude should be false.", falseExclude.excludeUnlistedClasses());
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.