Tests for TaskUtil

Added tests for the methods in TaskUtil
Work credit: thhughes