### Question:
SpoonPluginManager implements PluginTypeListener { @Override public void pluginRemoved( Object serviceObject ) { SpoonPluginInterface spoonPluginInterface = plugins.get( serviceObject ); if ( spoonPluginInterface == null ) { return; } SpoonPluginCategories categories = spoonPluginInterface.getClass().getAnnotation( SpoonPluginCategories.class ); if ( categories != null ) { for ( String cat : categories.value() ) { List<SpoonPluginInterface> categoryList = pluginCategoryMap.get( cat ); categoryList.remove( spoonPluginInterface ); } } if ( spoonPluginInterface.getPerspective() != null ) { getSpoonPerspectiveManager().removePerspective( spoonPluginInterface.getPerspective() ); } plugins.remove( serviceObject ); } private  SpoonPluginManager(); @Override void pluginAdded( final Object serviceObject ); @Override void pluginRemoved( Object serviceObject ); @Override void pluginChanged( Object serviceObject ); static SpoonPluginManager getInstance(); void applyPluginsForContainer( final String category, final XulDomContainer container ); List<SpoonPluginInterface> getPlugins(); void notifyLifecycleListeners( SpoonLifecycleListener.SpoonLifeCycleEvent evt );  }### Answer:
@Test public void testPluginRemoved() throws Exception { spoonPluginManager.pluginAdded( plugin1 ); spoonPluginManager.pluginRemoved( plugin1 ); verify( spoonPerspectiveManager ).removePerspective( spoonPerspective ); }