'If no volume is associated with the ``AttachVolume`` instance\'s
``blockdevice_id``, the underlying ``IBlockDeviceAPI`` should fail with
an ``UnknownVolume`` exception, and ``AttachVolume.run`` should return
a ``Deferred`` that fires with a ``Failure`` wrapping that exception.'

def test_missing(self):

    dataset_id = uuid4()
    deployer = create_blockdevicedeployer(self)
    bad_blockdevice_id = u'incorrect_blockdevice_id'
    change = AttachVolume(dataset_id=dataset_id, blockdevice_id=bad_blockdevice_id)
    failure = self.failureResultOf(run_state_change(change, deployer, InMemoryStatePersister()), UnknownVolume)
    self.assertEqual(bad_blockdevice_id, failure.value.blockdevice_id)
