Unit tests for new code upto mid term.

Signed-off-by: Ashutosh Dhundhara <ashutoshdhundhara@yahoo.com>

Fix coding style.

Signed-off-by: Ashutosh Dhundhara <ashutoshdhundhara@yahoo.com>