@Test
public void testUnload() {

  // given
  MockPlugin plugin = new MockPlugin();
  assumeTrue(loader.load(plugin));
  // when
  assertTrue(loader.unload(plugin), "The plugin was not unloaded");
  // then
  assertFalse(plugin.isLoaded());
  assertFalse(loader.getLoadedPlugins().contains(plugin));
  assertTrue(loader.getKnownPlugins().contains(plugin));
  assertFalse(dataTypes.isRegistered(MockPlugin.dataType));
  assertFalse(sourceTypes.isRegistered(MockPlugin.sourceType));
  assertFalse(components.isRegistered(MockPlugin.component));
  assertFalse(themes.isRegistered(MockPlugin.theme));
}