Few tests added, code cleaned-up.