So, I think an exam is a bad idea unless it's a pass/fail exam (ie no grades, you either understand the law or you do not) and there should be no meaningful time constraint when completing the exam. That's basically the system in most states today, except the training comes after someone without a law degree is elected.
There are state and federal oversight mechanisms with the power to remove bad judges.