I think what you said basically amounts to: God is testing whether you have faith in Him.
But where do you get that idea from? The idea that God wants to filter out those who have faith and reward the true believers comes from religion. You seem to be first assuming that religious claim is true, and then reasoning from there. If that claim is not true, then the only support that I have heard of for faith being valuable disappears.
Religious people need to ask themselves what they care more about: finding the truth, or having faith. If their goal is to find the truth, then using faith to do that will produce terrible results. Faith has been shown time and time again to be a terrible mechanism of gaining knowledge about the universe. If that is your goal, you should instead use the best procedure humanity has found so far: the scientific method. If you did, you would find reason to not believe in most of the physical claims made in the Bible (or really any religious text). All that would be left are metaphysical claims (which are by definition unfalsifiable) and moral claims (normative statements telling you how you should behave). And I claim there is no reason why one should feel compelled to adopt these particular claims made in the religious texts as true (especially since the physical claims being false shows the texts as a whole are not infallible).
Now maybe you don't care about the truth and only care about having faith. Or maybe you are okay with using the scientific method to evaluate physical claims, but you choose to use faith when it comes to accepting metaphysical and moral claims. In either case, you should ask yourself, "Why?" Why do you value faith? What good does having faith add to your life? Could it be that valuing faith or using faith as a basis for how to live your life is in fact harming you?
RE: Why I will never give up Christianity