Package org.pentaho.test.platform.engine.core

Examples of org.pentaho.test.platform.engine.core.MicroPlatform.define()


public class DefaultPluginPerspectiveManagerTest {

  @Before
  public void init0() {
    MicroPlatform microPlatform = new MicroPlatform( "test-res/PluginManagerTest" );
    microPlatform.define( IPluginPerspectiveManager.class, DefaultPluginPerspectiveManager.class );
  }

  private IPluginPerspective createTestPerspective( final String id, final String title ) {
    IPluginPerspective perspective = new DefaultPluginPerspective();
    perspective.setId( id );
View Full Code Here


  @SuppressWarnings( "deprecation" )
  @Test( expected = PlatformPluginRegistrationException.class )
  public void testLoad_BadSolutionPath() throws PlatformPluginRegistrationException {
    MicroPlatform mp = new MicroPlatform( "test-res/SystemPathPluginProviderTest/system" );
    mp.define( ISolutionEngine.class, SolutionEngine.class );
    mp.init();

    provider.getPlugins( new StandaloneSession() );
  }
View Full Code Here

    PlatformInitializationException {
    // This test is to validate a bug that had existed where a solution path ending in '/' was causing
    // the PluginClassLoader to not be able to open plugin jars, thus you would get ClassNotFound exceptions
    // when accessing plugin classes.
    MicroPlatform mp = new MicroPlatform( getSolutionPath() + "/" );
    mp.define( ISolutionEngine.class, SolutionEngine.class );
    mp.define( IServiceManager.class, DefaultServiceManager.class );
    mp.define( IPluginProvider.class, Tst8PluginProvider.class ).start();

    // reload should register the beans
    pluginManager.reload();
View Full Code Here

    // This test is to validate a bug that had existed where a solution path ending in '/' was causing
    // the PluginClassLoader to not be able to open plugin jars, thus you would get ClassNotFound exceptions
    // when accessing plugin classes.
    MicroPlatform mp = new MicroPlatform( getSolutionPath() + "/" );
    mp.define( ISolutionEngine.class, SolutionEngine.class );
    mp.define( IServiceManager.class, DefaultServiceManager.class );
    mp.define( IPluginProvider.class, Tst8PluginProvider.class ).start();

    // reload should register the beans
    pluginManager.reload();
View Full Code Here

    // the PluginClassLoader to not be able to open plugin jars, thus you would get ClassNotFound exceptions
    // when accessing plugin classes.
    MicroPlatform mp = new MicroPlatform( getSolutionPath() + "/" );
    mp.define( ISolutionEngine.class, SolutionEngine.class );
    mp.define( IServiceManager.class, DefaultServiceManager.class );
    mp.define( IPluginProvider.class, Tst8PluginProvider.class ).start();

    // reload should register the beans
    pluginManager.reload();

    try {
View Full Code Here

  }

  @Test
  public void test8c_loadClass() throws PlatformInitializationException, PluginBeanException {
    MicroPlatform mp = new MicroPlatform( getSolutionPath() + "/" );
    mp.define( IPluginProvider.class, Tst8PluginProvider.class ).start();
    pluginManager.reload();
    pluginManager.loadClass( "PluginOnlyClass" );
    pluginManager.loadClass( "PluginOnlyClassSpringFile" );
  }
View Full Code Here

  @Before
  public void setUp() throws Exception {

    String solutionsRelativePath = "test-src/org/pentaho/test/platform/plugin/chartbeans/solutions";
    MicroPlatform mp = new MicroPlatform( solutionsRelativePath );
    mp.define( ISolutionEngine.class, Object.class );
    ISystemSettings settings = new XmlSimpleSystemSettings();
    mp.setSettingsProvider( settings );
    mp.init();
  }
View Full Code Here

    TestAction2.reset();
    TestAction3.reset();
    TestActionCustomParam.reset();

    MicroPlatform mp = new MicroPlatform();
    mp.define( "IScheduler2", TestQuartzScheduler.class ); //$NON-NLS-1$
    mp.define( IUserRoleListService.class, StubUserRoleListService.class );
    mp.define( UserDetailsService.class, StubUserDetailsService.class );
    mp.define( IAuditEntry.class, TestAuditEntry.class );
    mp.start();
View Full Code Here

    TestAction3.reset();
    TestActionCustomParam.reset();

    MicroPlatform mp = new MicroPlatform();
    mp.define( "IScheduler2", TestQuartzScheduler.class ); //$NON-NLS-1$
    mp.define( IUserRoleListService.class, StubUserRoleListService.class );
    mp.define( UserDetailsService.class, StubUserDetailsService.class );
    mp.define( IAuditEntry.class, TestAuditEntry.class );
    mp.start();

    SecurityHelper.getInstance().becomeUser( TEST_USER );
View Full Code Here

    TestActionCustomParam.reset();

    MicroPlatform mp = new MicroPlatform();
    mp.define( "IScheduler2", TestQuartzScheduler.class ); //$NON-NLS-1$
    mp.define( IUserRoleListService.class, StubUserRoleListService.class );
    mp.define( UserDetailsService.class, StubUserDetailsService.class );
    mp.define( IAuditEntry.class, TestAuditEntry.class );
    mp.start();

    SecurityHelper.getInstance().becomeUser( TEST_USER );
    jobParams = new HashMap<String, Serializable>();
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.