Add tests for some methods in utils.py
This patch contains another fix of clone_distgit_repo. Config always
has git_user and its default value is an empty string. So, it makes no
sense to call hasattr to check if git_user exists.
Signed-off-by: Chenxiong Qi <cqi@redhat.com>