Before we can progress from one school class to another, we have to have a test.
The purpose of the test is not so that we will fail - but to enable us to go forward.
That is what God does. He tests us so that we can go forward.
Gen 22:1-2 Some time later God tested Abraham. He said to him, 'Abraham!'
'Here I am,' he replied.
Then God said, 'Take your son, your only son, Isaac, whom you love, and go to the region of Moriah. Sacrifice him there as a burnt offering on one of the mountains I will tell you about.'