'``RegisterVolume.run`` register a blockdevice mapping in the persistent
state.'

@given(dataset_id=uuids(), blockdevice_id=text())
def test_run(self, dataset_id, blockdevice_id):

    state_persister = InMemoryStatePersister()
    api = UnusableAPI()
    deployer = BlockDeviceDeployer(hostname=u'192.0.2.1', node_uuid=uuid4(), block_device_api=api)
    RegisterVolume(dataset_id=dataset_id, blockdevice_id=blockdevice_id).run(deployer, state_persister)
    self.assertEqual(state_persister.get_state().blockdevice_ownership, {dataset_id: blockdevice_id})
