self-congratulation (n.)
1630s, from self- + congratulation.