Added a unit test case for Counter.