@Test
public void testAddPortfolio() {
final ManageablePortfolio target = new ManageablePortfolio("Portfolio A");
target.getRootNode().setName("RootNode");
target.getRootNode().addChildNode(new ManageablePortfolioNode("Child"));
final PortfolioDocument request = new PortfolioDocument(target);
final PortfolioDocument result = new PortfolioDocument(target);
result.setUniqueId(UID);
when(_underlying.add(same(request))).thenReturn(result);
Response test = _resource.add(_uriInfo, request);
assertEquals(Status.CREATED.getStatusCode(), test.getStatus());
assertSame(result, test.getEntity());