when(execution.getVariable(ProcessVariables.INSTANCE_IDS)).thenReturn(instanceIds);
when(client.describeInstances(Matchers.<DescribeInstancesRequest>any()))
.thenReturn(new DescribeInstancesResult()
.withReservations(new Reservation().withInstances(
new Instance().withInstanceId("i-123").withPublicDnsName("i1.amazonaws.com")
.withPublicIpAddress("1.2.3.4").withPrivateDnsName("i1.internal").withPrivateIpAddress("10.1.2.3"),
new Instance().withInstanceId("i-456").withPublicDnsName("i2.amazonaws.com")
.withPublicIpAddress("5.6.7.8").withPrivateDnsName("i2.internal").withPrivateIpAddress("10.4.5.6")
)));
ProcessVariablesCollector collector = new ProcessVariablesCollector();
collector.install(execution);