def METHOD_NAME(make_stubber, error_code):
    orgs_client = boto3.client('organizations')
    orgs_stubber = make_stubber(orgs_client)
    pol_type = 'TAG_POLICY'
    policies = [make_policy(index, pol_type) for index in range(5)]
    orgs_stubber.stub_list_policies(pol_type, policies, error_code=error_code)
    if error_code is None:
        got_policies = organizations_policies.list_policies(pol_type, orgs_client)
        assert [got['Id'] for got in got_policies] == \
               [had['id'] for had in policies]
    else:
        with pytest.raises(ClientError) as exc_info:
            organizations_policies.list_policies(pol_type, orgs_client)
        assert exc_info.value.response['Error']['Code'] == error_code