'This test case checks if \'_do_request()\' method returns
appropriate status_code (200) and result (text converted to json),
while status_code returned by request is in one of fourth eligible
statuses'

@mock.patch.object(requests, 'request')
def test_do_request_possible_statuses(self, request_mock):

    for status_code in self.statuses:
        request_mock.return_value.status_code = status_code
        request_mock.return_value.text = '{"test":    "test"}'
        attestation_service = trusted_filter.AttestationService()
        (status, result) = attestation_service._do_request('POST', 'PollHosts', {}, {})
        self.assertEqual(requests.codes.OK, status)
        self.assertEqual(jsonutils.loads(request_mock.return_value.text), result)
