def test_prepare_resource_config():
    resource_config = _Job._prepare_resource_config(INSTANCE_COUNT, INSTANCE_TYPE, VOLUME_SIZE, None)

    assert resource_config == {
        'InstanceCount': INSTANCE_COUNT,
        'InstanceType': INSTANCE_TYPE,
        'VolumeSizeInGB': VOLUME_SIZE
    }
def test_prepare_resource_config_with_volume_kms():
    resource_config = _Job._prepare_resource_config(INSTANCE_COUNT, INSTANCE_TYPE, VOLUME_SIZE, VOLUME_KMS_KEY)

    assert resource_config == {
        'InstanceCount': INSTANCE_COUNT,
        'InstanceType': INSTANCE_TYPE,
        'VolumeSizeInGB': VOLUME_SIZE,
        'VolumeKmsKeyId': VOLUME_KMS_KEY
    }
Esempio n. 3
0
def test_prepare_resource_config():
    resource_config = _Job._prepare_resource_config(INSTANCE_COUNT,
                                                    INSTANCE_TYPE, VOLUME_SIZE,
                                                    None)

    assert resource_config == {
        "InstanceCount": INSTANCE_COUNT,
        "InstanceType": INSTANCE_TYPE,
        "VolumeSizeInGB": VOLUME_SIZE,
    }
Esempio n. 4
0
def test_prepare_resource_config_with_volume_kms():
    resource_config = _Job._prepare_resource_config(INSTANCE_COUNT,
                                                    INSTANCE_TYPE, VOLUME_SIZE,
                                                    VOLUME_KMS_KEY)

    assert resource_config == {
        "InstanceCount": INSTANCE_COUNT,
        "InstanceType": INSTANCE_TYPE,
        "VolumeSizeInGB": VOLUME_SIZE,
        "VolumeKmsKeyId": VOLUME_KMS_KEY,
    }
Esempio n. 5
0
def test_prepare_resource_config():
    resource_config = _Job._prepare_resource_config(INSTANCE_COUNT, INSTANCE_TYPE, VOLUME_SIZE)

    assert resource_config['InstanceCount'] == INSTANCE_COUNT
    assert resource_config['InstanceType'] == INSTANCE_TYPE
    assert resource_config['VolumeSizeInGB'] == VOLUME_SIZE