'When supplied with a configuration containing a dataset with a null
size, ``BlockDeviceDeployer.calculate_changes`` returns a
``CreateBlockDeviceDataset`` for a dataset with a size fixed to the
minimum allowed Rackspace volume size.
XXX: Make the default size configurable.  FLOC-2679'

def test_dataset_without_maximum_size(self):

    node_id = uuid4()
    node_address = u'192.0.2.1'
    dataset_id = unicode(uuid4())
    requested_dataset = Dataset(dataset_id=dataset_id, maximum_size=None)
    configuration = Deployment(nodes={Node(uuid=node_id, manifestations={dataset_id: Manifestation(dataset=requested_dataset, primary=True)})})
    node_state = NodeState(uuid=node_id, hostname=node_address, applications=None, manifestations={}, devices={}, paths={})
    state = DeploymentState(nodes={node_state})
    deployer = create_blockdevicedeployer(self, hostname=node_address, node_uuid=node_id)
    local_state = local_state_from_shared_state(node_state=node_state, nonmanifest_datasets={})
    changes = deployer.calculate_changes(configuration, state, local_state)
    expected_size = int(RACKSPACE_MINIMUM_VOLUME_SIZE.to_Byte())
    self.assertEqual(in_parallel(changes=[CreateBlockDeviceDataset(dataset_id=UUID(dataset_id), maximum_size=expected_size)]), changes)
