Add more functions and tests to Util.