Deuteronomy 13:3

you shall not listen to the words of that prophet or that dreamer of dreams. For the Lord your God is testing you, to know whether you love the Lord your God with all your heart and with all your soul.