'``CreateDataset.run()`` creates the named volume with a ``VolumeSize``
instance respecting the maximum_size passed in from the
``AttachedVolume``.'

def test_creates_respecting_size(self):

    EXPECTED_SIZE_BYTES = ((1024 * 1024) * 100)
    EXPECTED_SIZE = VolumeSize(maximum_size=EXPECTED_SIZE_BYTES)
    volume_service = create_volume_service(self)
    deployer = P2PManifestationDeployer(u'example.com', volume_service)
    volume = APPLICATION_WITH_VOLUME_SIZE.volume
    create = CreateDataset(dataset=volume.dataset)
    create.run(deployer, state_persister=InMemoryStatePersister())
    enumerated_volumes = list(self.successResultOf(volume_service.enumerate()))
    expected_volume = volume_service.get(_to_volume_name(volume.dataset.dataset_id), size=EXPECTED_SIZE)
    self.assertIn(expected_volume, enumerated_volumes)
    self.assertEqual(expected_volume.size, EXPECTED_SIZE)
