'A call to :py:obj:`Context.set_client_ca_list` after a call to
:py:obj:`Context.add_client_ca` replaces the CA name specified by the former
call with the names specified by the latter cal.'

def test_set_after_add_client_ca(self):

    cacert = load_certificate(FILETYPE_PEM, root_cert_pem)
    secert = load_certificate(FILETYPE_PEM, server_cert_pem)
    clcert = load_certificate(FILETYPE_PEM, server_cert_pem)
    cadesc = cacert.get_subject()
    sedesc = secert.get_subject()
    def set_replaces_add_ca(ctx):
        ctx.add_client_ca(clcert)
        ctx.set_client_ca_list([cadesc])
        ctx.add_client_ca(secert)
        return [cadesc, sedesc]
    self._check_client_ca_list(set_replaces_add_ca)
