public class BindLaunchSpecificationToFormParamsTest {
BindLaunchSpecificationToFormParams binder = new BindLaunchSpecificationToFormParams();
@Test
public void testApplyWithBlockDeviceMappings() throws UnknownHostException {
LaunchSpecification spec = LaunchSpecification.builder().instanceType(InstanceType.T1_MICRO).imageId("ami-123")
.mapNewVolumeToDevice("/dev/sda1", 120, true).build();
assertEquals(binder.apply(spec), ImmutableMap.of("LaunchSpecification.InstanceType", "t1.micro",
"LaunchSpecification.ImageId", "ami-123", "LaunchSpecification.BlockDeviceMapping.1.DeviceName",
"/dev/sda1", "LaunchSpecification.BlockDeviceMapping.1.Ebs.VolumeSize", "120",