Add tests for the Histogram code