If your employer asks you stay longer than two weeks (or the time period in your contract) you have no obligation to stay.
Also, your employer does not have to accept two weeks notice (unless it's in your contract). They can end your employment immediately. That can happen, so do be prepared to end your job when you give notice. Make sure you have all the information you need from your work computer and any other information you want to take with you ready to go.
Not sure how to tell your supervisor you are leaving? Here's what to say when you quit your job.
Synonyms: two week notice, giving notice, 2 week notice