Package com.google.appengine.datanucleus.test.jpa

Examples of com.google.appengine.datanucleus.test.jpa.HasMultiValuePropsJPA


  public void testFetchList() {
    Entity e = new Entity(HasMultiValuePropsJPA.class.getSimpleName());
    e.setProperty("strList", Utils.newArrayList("a", "b", "c"));
    ds.put(e);

    HasMultiValuePropsJPA pojo = em.find(HasMultiValuePropsJPA.class, e.getKey().getId());
    assertEquals(Utils.newArrayList("a", "b", "c"), pojo.getStrList());
  }
View Full Code Here


  public void testFetchLinkedList() {
    Entity e = new Entity(HasMultiValuePropsJPA.class.getSimpleName());
    e.setProperty("strLinkedList", Utils.newArrayList("a", "b", "c"));
    ds.put(e);

    HasMultiValuePropsJPA pojo = em.find(HasMultiValuePropsJPA.class, e.getKey().getId());
    assertEquals(Utils.newLinkedList("a", "b", "c"), pojo.getStrLinkedList());
  }
View Full Code Here

  public void testFetchHashSet() {
    Entity e = new Entity(HasMultiValuePropsJPA.class.getSimpleName());
    e.setProperty("strHashSet", Utils.newArrayList("a", "b", "c"));
    ds.put(e);

    HasMultiValuePropsJPA pojo = em.find(HasMultiValuePropsJPA.class, e.getKey().getId());
    assertEquals(Utils.newHashSet("a", "b", "c"), pojo.getStrHashSet());
  }
View Full Code Here

  public void testFetchLinkedHashSet() {
    Entity e = new Entity(HasMultiValuePropsJPA.class.getSimpleName());
    e.setProperty("strLinkedHashSet", Utils.newArrayList("a", "b", "c"));
    ds.put(e);

    HasMultiValuePropsJPA pojo = em.find(HasMultiValuePropsJPA.class, e.getKey().getId());
    assertEquals(Utils.newHashSet("a", "b", "c"), pojo.getStrLinkedHashSet());
  }
View Full Code Here

  public void testFetchSortedSet() {
    Entity e = new Entity(HasMultiValuePropsJPA.class.getSimpleName());
    e.setProperty("strSortedSet", Utils.newArrayList("c", "b", "a"));
    ds.put(e);

    HasMultiValuePropsJPA pojo = em.find(HasMultiValuePropsJPA.class, e.getKey().getId());
    assertEquals(Utils.newHashSet("a", "b", "c"), pojo.getStrSortedSet());
  }
View Full Code Here

  public void testFetchTreeSet() {
    Entity e = new Entity(HasMultiValuePropsJPA.class.getSimpleName());
    e.setProperty("strTreeSet", Utils.newArrayList("c", "b", "a"));
    ds.put(e);

    HasMultiValuePropsJPA pojo = em.find(HasMultiValuePropsJPA.class, e.getKey().getId());
    assertEquals(Utils.newTreeSet("a", "b", "c"), pojo.getStrTreeSet());
  }
View Full Code Here

  public void testFetchCollection() {
    Entity e = new Entity(HasMultiValuePropsJPA.class.getSimpleName());
    e.setProperty("intColl", Utils.newArrayList(2, 3, 4));
    ds.put(e);

    HasMultiValuePropsJPA pojo = em.find(HasMultiValuePropsJPA.class, e.getKey().getId());
    assertEquals(Utils.newArrayList(2, 3, 4), pojo.getIntColl());
  }
View Full Code Here

TOP

Related Classes of com.google.appengine.datanucleus.test.jpa.HasMultiValuePropsJPA

Copyright © 2018 www.massapicom. 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.