assertNull(futureGet.getData());
}
@Test
public void testPutMinorityFailed() throws ClassNotFoundException, IOException, NoPeerConnectionException {
NetworkManager nodeA = network.get(0);
NetworkManager nodeB = network.get(1);
nodeB.getConnection().getPeer().getPeerBean().storage(new TestPutFailureStorage());
H2HTestData data = new H2HTestData(NetworkTestUtil.randomString());
Parameters parameters = new Parameters().setLocationKey(nodeA.getNodeId())
.setContentKey(NetworkTestUtil.randomString()).setData(data);
boolean success = nodeB.getDataManager().put(parameters);
Assert.assertTrue(success);
FutureGet futureGet = nodeB.getDataManager().getUnblocked(parameters);
futureGet.awaitUninterruptibly();
assertEquals(data.getTestString(), ((H2HTestData) futureGet.getData().object()).getTestString());
}