Why does Hashem record Avraham's praises here?
Rashi #1: Hashem is saying here - 'Shall I hide My plans from Avraham, who is so precious to Me that he will become a great nation, through whom all the nations of the world will be blessed'?
Rashi #2 (citing a Midrash): Because of the principle 'Zeicher Tzadik li'Verachah' - When one mentions a Tzadik by name one blesses him.
Ramban: Seeing as Avraham would be a source of blessing for the whole world, Hashem had to inform him of the impending destruction of S'dom, so that people would not wonder how Hashem could hide such a major decision from him, or why Avraham could be so cruel 1 as to make no effort to save his neighbors by praying on their behalf. Furthermore, revealing Hashem's secret decision to him will be worthwhile, seeing as, since he is fully aware that Hashem does justice combined with charity, he will teach his children (and adherents) to go in Hashem's ways. Consequently, he will Daven on their behalf, that, if they will follow that path, they should be spared; but if they don't, in which case they are completely guilty, he will agree with Hashem's judgment.
Ohr Yechezkel Midos p.104: Is it cruelty not to pray for Resha'im? Yes! This is an obligation of man, and his primary Sheleimus.