PackageConfigData packageConfigData = new PackageConfigData( "default" );
packageConfigData.setUuid( "defaultUuid" );
presenter.onModuleSelected(
new ModuleFormatsGridPlace(
packageConfigData,
"Rules",
new String[]{AssetFormats.DRL, AssetFormats.BUSINESS_RULE} ) );
ArgumentCaptor<ModuleFormatsGridPlace> moduleFormatsArgumentCaptor = ArgumentCaptor.forClass( ModuleFormatsGridPlace.class );
verify( placeController ).goTo( moduleFormatsArgumentCaptor.capture() );
ModuleFormatsGridPlace moduleFormatsGridPlace = moduleFormatsArgumentCaptor.getValue();
assertEquals( "defaultUuid",
moduleFormatsGridPlace.getPackageConfigData().getUuid() );
assertEquals( "default",
moduleFormatsGridPlace.getPackageConfigData().getName() );
assertEquals( "Rules",
moduleFormatsGridPlace.getTitle() );
assertContains( moduleFormatsGridPlace.getFormats(),
AssetFormats.DRL );
assertContains( moduleFormatsGridPlace.getFormats(),
AssetFormats.BUSINESS_RULE );
}