Praise be to Allaah.
This cheating on the part of the teacher is haraam, and it is also haraam for her to single out and favour one student. If she likes her because she is taken with her prettiness, beauty, energy, knowledge, intelligence or character, then she may praise her for that, but helping her to cheat is haraam. With regard to the second part of the question, yes, this is correct. The hadeeth says: “If you hear the voice of the rooster, then ask Allaah of His bounty, for it has seen an angel. But if you hear the braying a donkey then seek refuge with Allaah from the Shaytaan, for it has seen a devil.”