#216: add util methods for package
#216: add test files;