ContinuumBuildsPlugin implements PanelPlugin, ConfigurablePanel<ContinuumModel> { public ContinuumModel getModel( Project project ) { ContinuumModel extensionModel = (ContinuumModel) project.getExtensionModel( getId() ); if ( extensionModel == null ) { extensionModel = new ContinuumModel(); project.addExtensionModel( extensionModel ); } return extensionModel; }  List<PanelItem> getItems( Project project ); String getTitle( Project project ); ContinuumModel getModel( Project project ); String getId();  }
@Test public void testGetModel() { assert project.getExtensionModel( "continuum-builds" ) == null; ContinuumModel model = plugin.getModel( project ); assert model == project.getExtensionModel( "continuum-builds" ); assert model == plugin.getModel( project ); }