Added unit test code for dot product.