Sufyan (may Allah have mercy on him) narrates from Ibn Abi Najil (may Allah have mercy on him) or from someone else, who narrates from Mujahid (may Allah have mercy on him) that regarding the statement of Allah the Exalted «إِنِّيأَعْلَمُمَالَاتَعْلَمُونَ», he said: "Allah the Exalted knew that Iblis would disobey, and He created him for that purpose."
Hadith Referenceسنن سعید بن منصور / كتاب التفسير / 184