This will not be reached if the assertion fails; use a try/finally.