Add test case for `count` method