Added hunit tests