when(byteStreamManager.store(null, content.getBytes())).thenReturn("myPid");
// execute test
DigitalObjectManager digitalObjectManager = new DigitalObjectManager();
digitalObjectManager.setByteStreamManager(byteStreamManager);
digitalObjectManager.moveDataToStorage(object);
// verify results
assertNull(object.getData().getData());
assertEquals("myPid", object.getPid());
assertTrue(object.getSizeInBytes() > 0);