Package com.getperka.flatpack.domain

Examples of com.getperka.flatpack.domain.Manager


    toReturn.getAddress().setStreet("street");
    return toReturn;
  }

  protected Manager makeManager() {
    Manager toReturn = managers.get();
    toReturn.setName("Manager Name");
    toReturn.getAddress().setStreet("manager street");
    return toReturn;
  }
View Full Code Here


    check(employee, employee2);
  }

  @Test
  public void testImpliedProperties() throws IOException {
    Manager manager = makeManager();
    Employee employeeA = makeEmployee();
    Employee employeeB = makeEmployee();

    // A -> manager -> B
    employeeA.setManager(manager);
    manager.getEmployees().add(employeeB);

    Employee employeeA2 = deepPack(Employee.class, employeeA);
    assertEquals(2, employeeA2.getManager().getEmployees().size());
    for (Employee toTest : employeeA2.getManager().getEmployees()) {
      if (employeeA.equals(toTest)) {
View Full Code Here

  Visitors visitors;

  @Test
  public void test() {
    // Create a cyclic datastructure
    Manager manager = makeManager();
    Employee employee = makeEmployee();

    manager.setEmployees(Collections.singletonList(employee));
    employee.setManager(manager);

    MyVisitor visitor = new MyVisitor();
    visitors.visit(visitor, employee);
    assertTrue(visitor.sawEmployee);
View Full Code Here

TOP

Related Classes of com.getperka.flatpack.domain.Manager

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.