No I’ve never been in such situation but personally I’d confess and then let cards fall where they may. If I get fired I get fired but maybe I’d just be written up. Regardless I’d rather know than worry about the unknown
Did you punch someone else’s time card because they asked? You don’t have to answer