ENH/TST: Change goto to context manager function and add gremove