tests for util functions
renamed some utils and added doctests