class RDSRaiderImpl implements RDSRaider {

    @Override
    public void startInstances(List<String> dbNames) {
        if (dbNames.isEmpty()) {
            throw new InvalidInputDataException("Empty dbNames list");
        }

        for (String dbName : dbNames) {
            DBInstance dbInstance = rdsDelegator.getAmazonRds().startDBInstance(
                    new StartDBInstanceRequest().withDBInstanceIdentifier(dbName));
            if (dbInstance == null) {
                throw new com.intuit.cloudraider.exceptions.ResourceNotFoundException("Unable to start DB instance: " + dbName);
            }

        }
    }

}

class RDSRaiderImplTest {

    @Autowired
    private RDSRaider rdsRaider;
    @Autowired
    private RDSDelegator rdsDelegator;
    private static AmazonRDS amazonRDS;
    private DBInstance dbInstance;

    @Test (expected = ResourceNotFoundException.class)
    public void testStartInvalidDbInstances() {

        PowerMockito.when(amazonRDS.startDBInstance(Mockito.anyObject())).thenReturn(null);
        rdsRaider.startInstances(Arrays.asList("blah"));

    }

}