def associate_static_ip(self, parameters, instance_id, elastic_ip):
    try:
      conn = self.open_connection(parameters)
      conn.associate_address(instance_id, elastic_ip)
    except EC2ResponseError as exception:
      self.handle_failure('Unable to associate Elastic IP {0} with instance ' \
        'ID {1} because: {2}'.format(elastic_ip, instance_id,
        exception.error_message))
Test if it install a module from cpan
dataset/ETHPy150Open AppScale/appscale-tools/lib/agents/ec2_agent.py/EC2Agent.associate_static_ip--crossover with--dataset/ETHPy150Open saltstack/salt/tests/unit/modules/cpan_test.py/CpanTestCase.test_install_error