### Question:
InfrastructureManager implements ServiceInfrastructure { @Override public String getParent() { if (parentsRoute.isEmpty()) { return ""; } return parentsRoute.get(0); } InfrastructureManager(); @Override void setParentsRoute(List<String> identifiers); @Override List<String> getParentsRoute(); @Override List<String> getChildDSRs(); @Override void addChildDSR(String identifier); @Override void setParent(String identifier); @Override String getParent(); void handleRegistration(List<String> identifiers); void handleUpdate(List<String> identifiers); void handleDelete(String identifier); boolean dbSynchronization(List<String> ids, Method method,
			int responsestatus);  }### Answer:
@Test public void testGetParent() { List<String> parents = new ArrayList<String>(); parents.add("test_paretn1"); parents.add("test_parent2"); parents.add("test_parent3"); try { manager.setParent(parents.get(0)); } catch (EmptyIdentifierFailureException e) { fail("The parents list was not empty!"); } catch (NullPointerFailureException e) { fail("Detecting NullPointerFailureException exception, but the input is valid."); } assertEquals(parents.get(0), manager.getParent()); try { manager.setParent(parents.get(1)); } catch (EmptyIdentifierFailureException e) { fail("The parents list was not empty!"); } catch (NullPointerFailureException e) { fail("Detecting NullPointerFailureException exception, but the input is valid."); } assertEquals(parents.get(1), manager.getParent()); }