fix: tasks come before tests in Function.doWhile and doUntil