def test_attached_when_policy_attached(self):
        self.conn.list_principal_policies.return_value = {'policies': [policy_ret]}
        result = salt_states['boto_iot.policy_attached']('test', policy_ret['policyName'], principal)
        self.assertTrue(result['result'])
        self.assertEqual(result['changes'], {})
start a local http server for testing
dataset/ETHPy150Open saltstack/salt/tests/unit/states/boto_iot_test.py/BotoIoTPolicyTestCase.test_attached_when_policy_attached--crossover with--dataset/ETHPy150Open linkedin/naarad/test/test_httpdownload.py/start_http_server