12-24-2015 10:18 AM
org.alfresco.repo.jscript.People.getPeople(String)
method but I am getting, null pointer exception.
java.lang.NullPointerException
at org.alfresco.repo.jscript.People.getPeoplePaging(People.java:572)
at org.alfresco.repo.jscript.People.getPeople(People.java:559)
at org.alfresco.repo.jscript.People.getPeople(People.java:539)
at org.alfresco.repo.jscript.People.getPeople(People.java:522)
at org.alfresco.repo.jscript.PeopleTest.testGetPeople(PeopleTest.java:110)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at junit.framework.TestCase.runTest(TestCase.java:176)
at junit.framework.TestCase.runBare(TestCase.java:141)
at junit.framework.TestResult$1.protect(TestResult.java:122)
at junit.framework.TestResult.runProtected(TestResult.java:142)
at junit.framework.TestResult.run(TestResult.java:125)
at junit.framework.TestCase.run(TestCase.java:129)
at junit.framework.TestSuite.runTest(TestSuite.java:255)
at junit.framework.TestSuite.run(TestSuite.java:250)
at org.junit.internal.runners.JUnit38ClassRunner.run(JUnit38ClassRunner.java:84)
at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:50)
at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:459)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:675)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:382)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:192)
org.alfresco.repo.jscript.People.getPeoplePaging(String, ScriptPagingDetails, String, Boolean)
. org.alfresco.repo.jscript.People.getPeople(String)
method?01-04-2016 10:42 AM
01-20-2016 11:14 PM
protected void onSetUpInTransaction() throws Exception
{
super.onSetUpInTransaction();
people = (CliQPeople) super.applicationContext.getBean("peopleScript");
AuthenticationUtil.setAdminUserAsFullyAuthenticatedUser();
createSite(SITE_NAME);
createUsers();
AssociateUsersAndSites();
}
@Test
public void test()
{
Scriptable result = people.getPeople("user*", 1000);
assertTrue(true);
assertNotNull(result);
assertEquals(new Double(1.0), result.get("length", result));
}
public Scriptable getPeople(String filter, int maxResults)
{…………..
}
Tags
Find what you came for
We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.