UniqueId oldPortfolioId = UniqueId.of("DbPrt", "101", "0");
PortfolioDocument base = _prtMaster.get(oldPortfolioId);
Map<String, String> oldAttr = base.getPortfolio().getAttributes();
assertNotNull(oldAttr);
ManageablePortfolio port = new ManageablePortfolio("NewName");
port.setUniqueId(oldPortfolioId);
port.setRootNode(base.getPortfolio().getRootNode());
Map<String, String> newAttr = getNewAttributes();
port.setAttributes(newAttr);
PortfolioDocument input = new PortfolioDocument(port);
PortfolioDocument updated = _prtMaster.update(input);
assertEquals(UniqueId.of("DbPrt", "101"), updated.getUniqueId().toLatest());
assertEquals(false, base.getUniqueId().getVersion().equals(updated.getUniqueId().getVersion()));