Plenty of examples in the threads. A number of applicants seem to have taken the test while being outside Canada but the issue of taking the oath outside Canada seems to be a little tricky. There are claims of IRCC allowing the oath from abroad, but conventional wisdom suggests otherwise. If you are in the US, getting back to Canada should not be an issue for the oath.