follows pep8
fix for non-dict instance while normalizing
add test case for normalizing