it is tested by any code that does mapValues + sum (.toList, .size, .toSet) .size is very common in the tests.