Add tests for product view

This commit adds some tests of the Product view code.