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

Examples of org.pentaho.test.platform.engine.core.MicroPlatform


    // utility to make this testing a bit easier
    localeTestUtil = new LocaleTestUtil();

    // create a platform
    MicroPlatform mp = new MicroPlatform( SOLUTION_PATH );
    try {
      mp.start();
    } catch ( PlatformInitializationException pie ) {
      pie.printStackTrace();
    }
  }
View Full Code Here


      }
    }

    localeTestUtil = new LocaleTestUtil();

    MicroPlatform mp = new MicroPlatform( SOLUTION_PATH );
    try {
      mp.start();
    } catch ( PlatformInitializationException pie ) {
      pie.printStackTrace();
    }
  }
View Full Code Here

@SuppressWarnings( "nls" )
public class DefaultPluginPerspectiveManagerTest {

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

  private static MicroPlatform microPlatform;

  @BeforeClass
  public static void init() throws PlatformInitializationException {
    StandaloneSession session = new StandaloneSession();
    microPlatform = new MicroPlatform( "test-src/web-servlet-solution" );
    microPlatform.define( ISolutionEngine.class, SolutionEngine.class );
    microPlatform.define( IServiceManager.class, DefaultServiceManager.class,
        IPentahoDefinableObjectFactory.Scope.GLOBAL );
    microPlatform.define( IPluginResourceLoader.class, PluginResourceLoader.class );
    microPlatform.define( IPluginProvider.class, SystemPathXmlPluginProvider.class );
View Full Code Here

  }

  @Before
  public void beforeTest() throws PlatformInitializationException {
    System.setProperty( SYSTEM_PROPERTY, "MODE_INHERITABLETHREADLOCAL" );
    mp = new MicroPlatform();
    mp.defineInstance( "tenantedUserNameUtils", tenantedUserNameUtils );
    mp.define( IPluginManager.class, DefaultPluginManager.class, Scope.GLOBAL );
    mp.defineInstance( IAuthorizationPolicy.class, authorizationPolicy );
    mp.defineInstance( ITenantManager.class, tenantManager );
    mp.define( ITenant.class, Tenant.class );
View Full Code Here

   */
  @SuppressWarnings( "deprecation" )
  @Before
  public void init0() throws ServiceInitializationException {
    // set solution path to a place that hosts an axis config file
    microPlatform = new MicroPlatform( "test-res/AxisWebServiceManagerTest/", "http://test/" );
    assertNotNull( PentahoSystem.getObjectFactory() );
    microPlatform.define( ISolutionEngine.class, SolutionEngine.class );
    assertNotNull( PentahoSystem.getObjectFactory() );
    microPlatform.define( IPluginManager.class, DefaultPluginManager.class, Scope.GLOBAL );
    microPlatform.define( IServiceManager.class, DefaultServiceManager.class, Scope.GLOBAL );
View Full Code Here

  SystemPathXmlPluginProvider provider = null;

  @Before
  public void init() {
    microPlatform = new MicroPlatform( "test-res/SystemPathPluginProviderTest/" );
    microPlatform.define( ISolutionEngine.class, SolutionEngine.class );
    microPlatform.define( IPluginPerspectiveManager.class, DefaultPluginPerspectiveManager.class );

    provider = new SystemPathXmlPluginProvider();
  }
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

  protected String solutionPath = "test-res/PluginManagerTest";

  @Before
  public void init0() {
    PentahoSystem.clearObjectFactory();
    microPlatform = new MicroPlatform( getSolutionPath() );
    microPlatform.define( ISolutionEngine.class, SolutionEngine.class );
    microPlatform.define( IPluginProvider.class, SystemPathXmlPluginProvider.class );
    microPlatform.define( IServiceManager.class, DefaultServiceManager.class, Scope.GLOBAL );
    microPlatform.define( IUnifiedRepository.class, FileSystemBackedUnifiedRepository.class, Scope.GLOBAL );
    FileSystemBackedUnifiedRepository repo =
View Full Code Here

  public void test8b_getBeanFromPluginClassloader_altSolutionPath() throws PluginBeanException,
    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();

    try {
View Full Code Here

TOP

Related Classes of org.pentaho.test.platform.engine.core.MicroPlatform

Copyright © 2018 www.massapicom. 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.