Why Allah Has Tested People Despite Having Knowledge About Everything
Human beings are created to go through the test of choosing right from wrong, for which they were given innate knowledge of right and wrong. This is a comprehensive test of honesty that applies to their intellect and sense of ethics and morality. They will be judged by God according to the knowledge available to them, their conduct in the light of their knowledge and reasoning, and their deeds being moral or immoral.