Search in sources :

Example 91 with StandaloneSession

use of org.pentaho.platform.engine.core.system.StandaloneSession in project pentaho-platform by pentaho.

the class DefaultBackingRepositoryLifecycleManager method loginAsRepositoryAdmin.

protected void loginAsRepositoryAdmin() {
    StandaloneSession pentahoSession = new StandaloneSession(repositoryAdminUsername);
    pentahoSession.setAuthenticated(repositoryAdminUsername);
    final List<GrantedAuthority> repositoryAdminAuthorities = new ArrayList<GrantedAuthority>();
    final String password = "ignored";
    UserDetails repositoryAdminUserDetails = new User(repositoryAdminUsername, password, true, true, true, true, repositoryAdminAuthorities);
    Authentication repositoryAdminAuthentication = new UsernamePasswordAuthenticationToken(repositoryAdminUserDetails, password, repositoryAdminAuthorities);
    PentahoSessionHolder.setSession(pentahoSession);
    // this line necessary for Spring Security's MethodSecurityInterceptor
    SecurityContextHolder.getContext().setAuthentication(repositoryAdminAuthentication);
}
Also used : UserDetails(org.springframework.security.core.userdetails.UserDetails) User(org.springframework.security.core.userdetails.User) StandaloneSession(org.pentaho.platform.engine.core.system.StandaloneSession) Authentication(org.springframework.security.core.Authentication) GrantedAuthority(org.springframework.security.core.GrantedAuthority) ArrayList(java.util.ArrayList) UsernamePasswordAuthenticationToken(org.springframework.security.authentication.UsernamePasswordAuthenticationToken)

Example 92 with StandaloneSession

use of org.pentaho.platform.engine.core.system.StandaloneSession in project pentaho-platform by pentaho.

the class MondrianCatalogHelperIT method testAddCatalog.

@Test
public void testAddCatalog() throws Exception {
    final String mondrianFolderPath = ClientRepositoryPaths.getEtcFolderPath() + RepositoryFile.SEPARATOR + "mondrian";
    UnifiedRepositoryTestUtils.stubGetFolder(repo, mondrianFolderPath);
    // return no children
    UnifiedRepositoryTestUtils.stubGetChildren(repo, mondrianFolderPath);
    final String steelWheelsFolderPath = mondrianFolderPath + RepositoryFile.SEPARATOR + CATALOG_NAME;
    UnifiedRepositoryTestUtils.stubGetFileDoesNotExist(repo, steelWheelsFolderPath);
    UnifiedRepositoryTestUtils.stubCreateFolder(repo, steelWheelsFolderPath);
    final String metadataPath = steelWheelsFolderPath + RepositoryFile.SEPARATOR + "metadata";
    UnifiedRepositoryTestUtils.stubCreateFile(repo, metadataPath);
    final String olapFolderPath = ClientRepositoryPaths.getEtcFolderPath() + RepositoryFile.SEPARATOR + "olap-servers";
    UnifiedRepositoryTestUtils.stubGetFolder(repo, olapFolderPath);
    // return no children
    UnifiedRepositoryTestUtils.stubGetChildren(repo, olapFolderPath);
    IPentahoSession session = new StandaloneSession("admin");
    MondrianCatalog cat = createTestCatalog();
    File file = new File(TestResourceLocation.TEST_RESOURCES + "/solution/test/charts/steelwheels.mondrian.xml");
    String mondrianSchema = IOUtils.toString(new FileInputStream(file));
    session.setAttribute("MONDRIAN_SCHEMA_XML_CONTENT", mondrianSchema);
    MondrianCatalogHelper helperSpy = spy(helper);
    IAclNodeHelper aclNodeHelper = mock(IAclNodeHelper.class);
    doNothing().when(aclNodeHelper).setAclFor(any(RepositoryFile.class), any(RepositoryFileAcl.class));
    doReturn(aclNodeHelper).when(helperSpy).getAclHelper();
    doReturn(true).when(helperSpy).catalogExists(any(MondrianCatalog.class), eq(session));
    helperSpy.addCatalog(cat, true, session);
    verify(repo).createFile(eq(UnifiedRepositoryTestUtils.makeIdObject(steelWheelsFolderPath)), argThat(UnifiedRepositoryTestUtils.isLikeFile(UnifiedRepositoryTestUtils.makeFileObject(metadataPath))), argThat(UnifiedRepositoryTestUtils.hasData(UnifiedRepositoryTestUtils.pathPropertyPair("/catalog/definition", "mondrian:/" + cat.getName()), UnifiedRepositoryTestUtils.pathPropertyPair("/catalog/datasourceInfo", cat.getDataSourceInfo()))), anyString());
    verify(repo).createFile(eq(UnifiedRepositoryTestUtils.makeIdObject(steelWheelsFolderPath)), argThat(UnifiedRepositoryTestUtils.isLikeFile(UnifiedRepositoryTestUtils.makeFileObject(steelWheelsFolderPath + RepositoryFile.SEPARATOR + "schema.xml"))), any(IRepositoryFileData.class), anyString());
    // cache should be cleared for this schema only
    verify(olapService, times(1)).getConnection(CATALOG_NAME, session);
    verify(mondrianCacheControl, times(1)).flushSchema(this.mondrianSchema);
}
Also used : IRepositoryFileData(org.pentaho.platform.api.repository2.unified.IRepositoryFileData) StandaloneSession(org.pentaho.platform.engine.core.system.StandaloneSession) IPentahoSession(org.pentaho.platform.api.engine.IPentahoSession) IAclNodeHelper(org.pentaho.platform.api.repository2.unified.IAclNodeHelper) RepositoryFile(org.pentaho.platform.api.repository2.unified.RepositoryFile) Matchers.anyString(org.mockito.Matchers.anyString) RepositoryFile(org.pentaho.platform.api.repository2.unified.RepositoryFile) File(java.io.File) RepositoryFileAcl(org.pentaho.platform.api.repository2.unified.RepositoryFileAcl) FileInputStream(java.io.FileInputStream) Test(org.junit.Test)

Example 93 with StandaloneSession

use of org.pentaho.platform.engine.core.system.StandaloneSession in project pentaho-platform by pentaho.

the class MondrianCatalogHelperIT method testNoDspApplied_WhenNoDynamicSchemaProcessorParameterInDataSourceInfo.

@Test
public void testNoDspApplied_WhenNoDynamicSchemaProcessorParameterInDataSourceInfo() throws Exception {
    final String replaceTemplate = "REPLACE_TEMPLATE";
    final String DATA_SOURCE_INFO_WITHOUT_DSP = "DataSource=TestDataSource";
    final String SCHEMA_MOCK = "Test Schema Mock " + replaceTemplate;
    MondrianCatalogHelper helperSpy = spy(helper);
    doReturn(SCHEMA_MOCK).when(helperSpy).docAtUrlToString(anyString(), any(IPentahoSession.class));
    IPentahoSession session = new StandaloneSession("admin");
    String schema = helperSpy.applyDSP(session, DATA_SOURCE_INFO_WITHOUT_DSP, SCHEMA_MOCK);
    assertNotNull(schema);
    verify(helperSpy).docAtUrlToString(anyString(), any(IPentahoSession.class));
    assertFalse(schema.contains("REPLACE_TOKEN"));
}
Also used : StandaloneSession(org.pentaho.platform.engine.core.system.StandaloneSession) IPentahoSession(org.pentaho.platform.api.engine.IPentahoSession) Matchers.anyString(org.mockito.Matchers.anyString) Test(org.junit.Test)

Example 94 with StandaloneSession

use of org.pentaho.platform.engine.core.system.StandaloneSession in project pentaho-platform by pentaho.

the class ChartIT method testChartHelper_Null.

/*
   * public void testCategoryAreaChart() { runCategoryChartTest(JFreeChartEngine.AREA_CHART_TYPE,
   * "test/charts/areaChart.xml", "testAreaChart"); //$NON-NLS-1$ //$NON-NLS-2$ }
   * 
   * public void testCategoryBarChart() { runCategoryChartTest(JFreeChartEngine.BAR_CHART_TYPE,
   * "test/charts/barChart.xml", "testBarChart"); //$NON-NLS-1$ //$NON-NLS-2$ }
   * 
   * public void testCategoryLineChart() { runCategoryChartTest(JFreeChartEngine.LINE_CHART_TYPE,
   * "test/charts/lineChart.xml", "testLineChart"); //$NON-NLS-1$ //$NON-NLS-2$ }
   * 
   * public void testPieChart() { runPieChartTest(JFreeChartEngine.PIE_CHART_TYPE, "test/charts/pieChart.xml",
   * "testPieChart"); //$NON-NLS-1$ //$NON-NLS-2$ }
   */
/*
   * public void testChartHelper_DialChart() { String region = "Central"; //$NON-NLS-1$ ArrayList messages = new
   * ArrayList(); SimpleParameterProvider parameters = new SimpleParameterProvider();
   * parameters.setParameter("image-width", "450"); //$NON-NLS-1$ //$NON-NLS-2$ parameters.setParameter("image-height",
   * "300"); //$NON-NLS-1$ //$NON-NLS-2$ parameters.setParameter("REGION", region); //$NON-NLS-1$
   * parameters.setParameter("outer-params", "REGION"); //$NON-NLS-1$ //$NON-NLS-2$
   * parameters.setParameter("inner-param", "DEPARTMENT"); //$NON-NLS-1$ //$NON-NLS-2$ parameters.setParameter(
   * "drill-url", "SampleDashboard.jsp?region=" + region + "&amp;department={DEPARTMENT}&amp;measure={measure}");
   * //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ parameters.setParameter("series-name", "measure"); //$NON-NLS-1$
   * //$NON-NLS-2$ parameters.setParameter("chart-type", "DialChart"); //$NON-NLS-1$ //$NON-NLS-2$
   * parameters.setParameter("value", "550"); //$NON-NLS-1$ //$NON-NLS-2$ StringBuffer content = new StringBuffer();
   * StandaloneSession session = new StandaloneSession(Messages.getString("BaseTest.DEBUG_JUNIT_SESSION"));
   * //$NON-NLS-1$ ChartHelper.doChart("/test-src/solutions/samples/dashboard/departments.widget.xml", parameters,
   * content, session, messages, null); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ try { OutputStream os =
   * getOutputStream(SOLUTION_PATH, "ChartTest.testChartHelper_DialChart", ".html"); //$NON-NLS-1$ //$NON-NLS-2$
   * os.write(content.toString().getBytes()); } catch (Exception e) {
   * 
   * } }
   * 
   * public void testChartHelper_PieChart() { String region = "Central"; //$NON-NLS-1$ ArrayList messages = new
   * ArrayList(); SimpleParameterProvider parameters = new SimpleParameterProvider();
   * parameters.setParameter("image-width", "450"); //$NON-NLS-1$ //$NON-NLS-2$ parameters.setParameter("image-height",
   * "300"); //$NON-NLS-1$ //$NON-NLS-2$ parameters.setParameter("REGION", region); //$NON-NLS-1$
   * parameters.setParameter("outer-params", "REGION"); //$NON-NLS-1$ //$NON-NLS-2$
   * parameters.setParameter("inner-param", "DEPARTMENT"); //$NON-NLS-1$ //$NON-NLS-2$ parameters.setParameter(
   * "drill-url", "SampleDashboard.jsp?region=" + region + "&amp;department={DEPARTMENT}&amp;measure={measure}");
   * //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ parameters.setParameter("series-name", "measure"); //$NON-NLS-1$
   * //$NON-NLS-2$ parameters.setParameter("chart-type", "PieChart"); //$NON-NLS-1$ //$NON-NLS-2$ StringBuffer content =
   * new StringBuffer(); StandaloneSession session = new
   * StandaloneSession(Messages.getString("BaseTest.DEBUG_JUNIT_SESSION")); //$NON-NLS-1$
   * ChartHelper.doChart("/test-src/solutions/samples/dashboard/departments.widget.xml", parameters, content, session,
   * messages, null); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ try { OutputStream os = getOutputStream(SOLUTION_PATH,
   * "ChartTest.testChartHelper_PieChart", ".html"); //$NON-NLS-1$ //$NON-NLS-2$
   * os.write(content.toString().getBytes()); } catch (Exception e) {
   * 
   * } }
   * 
   * public void testChartHelper_PieGrid() { String region = "Central"; //$NON-NLS-1$ ArrayList messages = new
   * ArrayList(); SimpleParameterProvider parameters = new SimpleParameterProvider();
   * parameters.setParameter("image-width", "450"); //$NON-NLS-1$ //$NON-NLS-2$ parameters.setParameter("image-height",
   * "300"); //$NON-NLS-1$ //$NON-NLS-2$ parameters.setParameter("REGION", region); //$NON-NLS-1$
   * parameters.setParameter("outer-params", "REGION"); //$NON-NLS-1$ //$NON-NLS-2$
   * parameters.setParameter("inner-param", "DEPARTMENT"); //$NON-NLS-1$ //$NON-NLS-2$ parameters.setParameter(
   * "drill-url", "SampleDashboard.jsp?region=" + region + "&amp;department={DEPARTMENT}&amp;measure={measure}");
   * //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ parameters.setParameter("series-name", "measure"); //$NON-NLS-1$
   * //$NON-NLS-2$ parameters.setParameter("chart-type", "PieGrid"); //$NON-NLS-1$ //$NON-NLS-2$ StringBuffer content =
   * new StringBuffer(); StandaloneSession session = new
   * StandaloneSession(Messages.getString("BaseTest.DEBUG_JUNIT_SESSION")); //$NON-NLS-1$
   * ChartHelper.doChart(/test-src/solutions/samples/dashboard/departments.widget.xml", parameters, content, session,
   * messages, null); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ try { OutputStream os = getOutputStream(SOLUTION_PATH,
   * "ChartTest.testChartHelper_PieGrid", ".html"); //$NON-NLS-1$ //$NON-NLS-2$ os.write(content.toString().getBytes());
   * } catch (Exception e) {
   * 
   * } }
   * 
   * public void testChartHelper_BarChart() { String region = "Central"; //$NON-NLS-1$ ArrayList messages = new
   * ArrayList(); SimpleParameterProvider parameters = new SimpleParameterProvider();
   * parameters.setParameter("image-width", "450"); //$NON-NLS-1$ //$NON-NLS-2$ parameters.setParameter("image-height",
   * "300"); //$NON-NLS-1$ //$NON-NLS-2$ parameters.setParameter("REGION", region); //$NON-NLS-1$
   * parameters.setParameter("outer-params", "REGION"); //$NON-NLS-1$ //$NON-NLS-2$
   * parameters.setParameter("inner-param", "DEPARTMENT"); //$NON-NLS-1$ //$NON-NLS-2$ parameters.setParameter(
   * "drill-url", "SampleDashboard.jsp?region=" + region + "&amp;department={DEPARTMENT}&amp;measure={measure}");
   * //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ parameters.setParameter("series-name", "measure"); //$NON-NLS-1$
   * //$NON-NLS-2$ parameters.setParameter("chart-type", "BarChart"); //$NON-NLS-1$ //$NON-NLS-2$ StringBuffer content =
   * new StringBuffer(); StandaloneSession session = new
   * StandaloneSession(Messages.getString("BaseTest.DEBUG_JUNIT_SESSION")); //$NON-NLS-1$
   * ChartHelper.doChart("/test-src/solutions/samples/dashboard/departments.widget.xml", parameters, content, session,
   * messages, null); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ try { OutputStream os = getOutputStream(SOLUTION_PATH,
   * "ChartTest.testChartHelper_BarChart", ".html"); //$NON-NLS-1$ //$NON-NLS-2$
   * os.write(content.toString().getBytes()); } catch (Exception e) {
   * 
   * } }
   */
/*
   * public void testChartHelper_LineChart() { String region = "Central"; //$NON-NLS-1$ ArrayList messages = new
   * ArrayList(); SimpleParameterProvider parameters = new SimpleParameterProvider();
   * parameters.setParameter("image-width", "450"); //$NON-NLS-1$ //$NON-NLS-2$ parameters.setParameter("image-height",
   * "300"); //$NON-NLS-1$ //$NON-NLS-2$ parameters.setParameter("REGION", region); //$NON-NLS-1$
   * parameters.setParameter("outer-params", "REGION"); //$NON-NLS-1$ //$NON-NLS-2$
   * parameters.setParameter("inner-param", "DEPARTMENT"); //$NON-NLS-1$ //$NON-NLS-2$ parameters.setParameter(
   * "drill-url", "SampleDashboard.jsp?region=" + region + "&amp;department={DEPARTMENT}&amp;measure={measure}");
   * //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ parameters.setParameter("series-name", "measure"); //$NON-NLS-1$
   * //$NON-NLS-2$ parameters.setParameter("chart-type", "LineChart"); //$NON-NLS-1$ //$NON-NLS-2$ StringBuffer content
   * = new StringBuffer(); StandaloneSession session = new
   * StandaloneSession(Messages.getString("BaseTest.DEBUG_JUNIT_SESSION")); //$NON-NLS-1$
   * ChartHelper.doChart("/test-src/solutions/samples/dashboard/departments.widget.xml", parameters, content, session,
   * messages, null); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ try { OutputStream os = getOutputStream(SOLUTION_PATH,
   * "ChartTest.testChartHelper_LineChart", ".html"); //$NON-NLS-1$ //$NON-NLS-2$
   * os.write(content.toString().getBytes()); } catch (Exception e) {
   * 
   * } }
   */
/*
   * public void testChartHelper_AreaChart() { String region = "Central"; //$NON-NLS-1$ ArrayList messages = new
   * ArrayList(); SimpleParameterProvider parameters = new SimpleParameterProvider();
   * parameters.setParameter("image-width", "450"); //$NON-NLS-1$ //$NON-NLS-2$ parameters.setParameter("image-height",
   * "300"); //$NON-NLS-1$ //$NON-NLS-2$ parameters.setParameter("REGION", region); //$NON-NLS-1$
   * parameters.setParameter("outer-params", "REGION"); //$NON-NLS-1$ //$NON-NLS-2$
   * parameters.setParameter("inner-param", "DEPARTMENT"); //$NON-NLS-1$ //$NON-NLS-2$
   * parameters.setParameter("connection", "SampleData"); //$NON-NLS-1$ //$NON-NLS-2$ parameters.setParameter("query",
   * "select REGION, DEPARTMENT, MANAGER_NAME, EMAIL from DEPARTMENT_MANAGERS"); //$NON-NLS-1$ //$NON-NLS-2$
   * parameters.setParameter( "drill-url", "SampleDashboard.jsp?region=" + region +
   * "&amp;department={DEPARTMENT}&amp;measure={measure}"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
   * parameters.setParameter("series-name", "measure"); //$NON-NLS-1$ //$NON-NLS-2$
   * parameters.setParameter("chart-type", "AreaChart"); //$NON-NLS-1$ //$NON-NLS-2$ StringBuffer content = new
   * StringBuffer(); StandaloneSession session = new
   * StandaloneSession(Messages.getString("BaseTest.DEBUG_JUNIT_SESSION")); //$NON-NLS-1$
   * ChartHelper.doChart("/test-src/solutions/samples/dashboard/departments.widget.xml", parameters, content, session,
   * messages, null); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ try { OutputStream os = getOutputStream(SOLUTION_PATH,
   * "ChartTest.testChartHelper_AreaChart", ".html"); //$NON-NLS-1$ //$NON-NLS-2$
   * os.write(content.toString().getBytes()); } catch (Exception e) {
   * 
   * } }
   */
public void testChartHelper_Null() {
    // $NON-NLS-1$
    String region = "Central";
    ArrayList messages = new ArrayList();
    SimpleParameterProvider parameters = new SimpleParameterProvider();
    // $NON-NLS-1$ //$NON-NLS-2$
    parameters.setParameter("image-width", "450");
    // $NON-NLS-1$ //$NON-NLS-2$
    parameters.setParameter("image-height", "300");
    // $NON-NLS-1$
    parameters.setParameter("REGION", region);
    // $NON-NLS-1$ //$NON-NLS-2$
    parameters.setParameter("outer-params", "REGION");
    // $NON-NLS-1$ //$NON-NLS-2$
    parameters.setParameter("inner-param", "DEPARTMENT");
    parameters.setParameter("drill-url", // $NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
    "SampleDashboard.jsp?region=" + region + "&amp;department={DEPARTMENT}&amp;measure={measure}");
    // $NON-NLS-1$ //$NON-NLS-2$
    parameters.setParameter("series-name", "measure");
    // $NON-NLS-1$ //$NON-NLS-2$
    parameters.setParameter("chart-type", "");
    StringBuffer content = new StringBuffer();
    StandaloneSession session = // $NON-NLS-1$
    new StandaloneSession(Messages.getInstance().getString("BaseTest.DEBUG_JUNIT_SESSION"));
    PentahoSessionHolder.setSession(session);
    // $NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
    ChartHelper.doChart("/samples/dashboard/departments.widget.xml", parameters, content, session, messages, null);
    try {
        // $NON-NLS-1$ //$NON-NLS-2$
        OutputStream os = getOutputStream("ChartTest.testChartHelper_Null", ".html");
        os.write(content.toString().getBytes());
    } catch (Exception e) {
    // ignore
    }
}
Also used : StandaloneSession(org.pentaho.platform.engine.core.system.StandaloneSession) OutputStream(java.io.OutputStream) ArrayList(java.util.ArrayList) IOException(java.io.IOException) SimpleParameterProvider(org.pentaho.platform.engine.core.solution.SimpleParameterProvider)

Example 95 with StandaloneSession

use of org.pentaho.platform.engine.core.system.StandaloneSession in project pentaho-platform by pentaho.

the class ChartbeansIT method init0.

@Before
public void init0() {
    microPlatform = new MicroPlatform(TestResourceLocation.TEST_RESOURCES + "/solution/");
    microPlatform.define(ISolutionEngine.class, SolutionEngine.class);
    microPlatform.define(IChartBeansGenerator.class, DefaultChartBeansGenerator.class);
    microPlatform.define(IUnifiedRepository.class, FileSystemBackedUnifiedRepository.class, Scope.GLOBAL);
    FileSystemBackedUnifiedRepository repo = (FileSystemBackedUnifiedRepository) PentahoSystem.get(IUnifiedRepository.class);
    repo.setRootDir(new File(TestResourceLocation.TEST_RESOURCES + "/solution"));
    session = new StandaloneSession();
}
Also used : StandaloneSession(org.pentaho.platform.engine.core.system.StandaloneSession) MicroPlatform(org.pentaho.test.platform.engine.core.MicroPlatform) File(java.io.File) FileSystemBackedUnifiedRepository(org.pentaho.platform.repository2.unified.fs.FileSystemBackedUnifiedRepository) IUnifiedRepository(org.pentaho.platform.api.repository2.unified.IUnifiedRepository) Before(org.junit.Before)

Aggregations

StandaloneSession (org.pentaho.platform.engine.core.system.StandaloneSession)218 IPentahoSession (org.pentaho.platform.api.engine.IPentahoSession)74 ArrayList (java.util.ArrayList)46 Authentication (org.springframework.security.core.Authentication)39 Test (org.junit.Test)38 OutputStream (java.io.OutputStream)34 UsernamePasswordAuthenticationToken (org.springframework.security.authentication.UsernamePasswordAuthenticationToken)30 GrantedAuthority (org.springframework.security.core.GrantedAuthority)30 User (org.springframework.security.core.userdetails.User)30 SimpleGrantedAuthority (org.springframework.security.core.authority.SimpleGrantedAuthority)29 UserDetails (org.springframework.security.core.userdetails.UserDetails)29 SimpleOutputHandler (org.pentaho.platform.engine.core.output.SimpleOutputHandler)24 File (java.io.File)21 SimpleParameterProvider (org.pentaho.platform.engine.core.solution.SimpleParameterProvider)21 StandaloneObjectFactory (org.pentaho.platform.engine.core.system.objfac.StandaloneObjectFactory)21 StandaloneSpringPentahoObjectFactory (org.pentaho.platform.engine.core.system.objfac.StandaloneSpringPentahoObjectFactory)21 IPentahoUser (org.pentaho.platform.api.engine.security.userroledao.IPentahoUser)20 SimpleUrlFactory (org.pentaho.platform.util.web.SimpleUrlFactory)20 HashMap (java.util.HashMap)16 Before (org.junit.Before)16