Add proper tests for resubmitting jobs (sync and async)