### Question:
BundleStateManager { public boolean isBundleInstalled( String name ) { if ( bundleMap.containsKey( name ) ) { if ( bundleMap.get( name ) == BundleEvent.INSTALLED ) { return true; } } return false; } BundleStateManager(); void setState( String name, int state ); boolean isBundleInstalled( String name );  }### Answer:
@Test public void testIsBundleInstalled() { bundleStateManager.setState( BUNDLE_COMMON_UI, BundleEvent.INSTALLED ); assertTrue( bundleStateManager.isBundleInstalled( BUNDLE_COMMON_UI ) ); bundleStateManager.setState( BUNDLE_COMMON_UI, BundleEvent.UNINSTALLED ); assertFalse( bundleStateManager.isBundleInstalled( BUNDLE_COMMON_UI ) ); }