### Question:
CompactHashMap implements Map<K, V> { @Override public Set<K> keySet() { return new ViewSet(); } CompactHashMap();  CompactHashMap(int initialCapacity);  CompactHashMap(int initialCapacity, float loadFactor); @Override int size(); @Override boolean isEmpty(); @Override boolean containsKey(Object key); @Override boolean containsValue(Object value); @Override V get(Object key); @Override V put(K key, V value); @Override V remove(Object key); @Override void putAll(Map<? extends K, ? extends V> m); @Override void clear(); @Override Set<K> keySet(); @Override Collection<V> values(); @Override Set<Map.Entry<K, V>> entrySet();  }### Answer:
@Test void ensureKeyIteratorWorksForEmptyMap() { assertFalse(map.keySet().iterator().hasNext()); }