John Calvin defended the doctrine of election in A Treatise on the Eternal Predestination of God and countered a detractor named Pighius:
Some of our adversaries have preposterously asked, How can men be certain of their salvation if it lies in the secret counsel of God? I have replied in these statements, which are the truth. Since the certainty of salvation is “set forth” unto us in Christ, it is useless, and not without dishonour to Christ Himself, to pass over this fountain of life, which is thrown open that men may draw out of it, and to labour and toil in vain to draw the water of eternal life out of the hidden abysses of the mind and counsel of God! Paul testifies, indeed, that we were “chosen before the foundation of the world,” but it was “in Christ.”
Let no one, then, seek confidence in his own election of God anywhere else than “in Christ,” unless, indeed, he would blot out, and do away with, the “book of life” in which his name is written. God’s adoption of us “in Christ” is for no other end than that we should be considered His children …
Hence Christ, when dwelling on the eternal election of His own in the counsel of the Father, points out, at the same time, the ground on which their confidence may safely rest; where He says, “I have manifested Thy name unto the men which Thou gavest Me out of the world: Thine they were, and Thou gavest them Me; and they have kept Thy word” (John xvii. 6). We see here that God begins with Himself, when He condescends to choose us and give us to Christ. But He will have us begin with Christ, if we would know that we are numbered among His “peculiar people” …
If your doctrine and argument be true, says Pighius, that all the elect are thus secure in the hand of Christ “unto the end,” the condition of salvation on which Christ Himself lays down is proposed in vain, where He says, “He that endureth to the end shall be saved” (Matt. x. 22). Here, everyone must confess, that my opponent prevaricates. He had undertaken to prove that our confidence of our salvation could not consistently stand with our election of God. But now, his reasoning draws us away from that point, and leads us to prove that the former necessarily stands on the latter.
I thus find myself so perpetually tossed to and fro by the billows of this man’s violent attacks, that scarcely a moment passes in which I am not in danger of being drowned. But, as God ever upholds His elect to prevent them from sinking, I feel quite confident that I shall stand against all my adversary’s incessant storms. When Pighius asks me how I know that I am elected, my answer is, “Christ is, to me, more than a thousand witnesses.” For when I find myself engrafted into His body, my salvation rests in a place so safe, secure and tranquil, that it is as if I already realised it in heaven.
Don’t look for security in the secret things of the divine decree. Look to Jesus Christ to whom we are joined by the Holy Spirit through faith. “Christ is, to me, more than a thousand witnesses.”
“The secret things belong to the LORD our God, but the things that are revealed belong to us and to our children forever…” (Deut. 29:29). What does Jesus reveal? “All that the Father gives me will come to me, and whoever comes to me I will never cast out” (Jn. 6:37).
Listen to Calvin and the Mystery of Believing by John L. Thompson, speaking on the doctrine of predestination.