ScopeMap extends ReadOnlyEnumerationMap<Object> { public Object remove(Object key) { String skey = key(key); Object previous = context.getValue(skey); context.removeValue(skey); return (previous); } ScopeMap(AttributeExtractor context); void clear(); Set<Map.Entry<String, Object>> entrySet(); Set<String> keySet(); Object put(String key, Object value); void putAll(Map<? extends String, ? extends Object> map); Object remove(Object key);  }
@Test public void testRemoveObject() { expect(extractor.getValue("one")).andReturn(1); extractor.removeValue("one"); replay(extractor); assertEquals(new Integer(1), map.remove("one")); verify(extractor); }