If she confesses -by herself, not after the guy confronted her- as soon as possible, then I would not considering this as cheating.
But if she tries to hide what she did, if she lies about it, then yes, it's cheating.
Because, to me, cheating means to ***** the person's trust.