### Question:
MapExtractor implements TextMap { @Override public Iterator<Map.Entry<String, String>> iterator() { return extracted.entrySet().iterator(); } MapExtractor(MetaData metaData); @Override Iterator<Map.Entry<String, String>> iterator(); @Override void put(String key, String value);  }### Answer:
@Test void testExtractor() { MetaData metaData = MetaData.emptyInstance(); metaData = metaData.and("key", "value"); MapExtractor extractor = new MapExtractor(metaData); Iterator<Map.Entry<String, String>> iterator = extractor.iterator(); assertTrue(iterator.hasNext()); assertEquals("value", iterator.next().getValue()); }