public final class TestUtil extends Object
| Modifier and Type | Class and Description |
|---|---|
static interface |
TestUtil.SessionStrategy |
| Modifier and Type | Method and Description |
|---|---|
static void |
assertFileContains(@NotNull File haystack,
@NotNull String needle) |
static void |
closeRepo(javax.jcr.Repository repo) |
static void |
compositeWithFixture(@NotNull org.apache.jackrabbit.oak.run.cli.NodeStoreFixture fixture,
@NotNull TestUtil.SessionStrategy sessionStrategy) |
static void |
compositeWithFixtures(@NotNull org.apache.jackrabbit.oak.run.cli.NodeStoreFixture fixture,
@NotNull org.apache.jackrabbit.oak.run.cli.NodeStoreFixture globalFixture,
@NotNull TestUtil.SessionStrategy sessionStrategy) |
static net.adamcin.oakpal.core.OakMachine.Builder |
fromPlan(@NotNull javax.json.JsonObject planJson) |
static org.apache.jackrabbit.oak.run.cli.NodeStoreFixture |
getReadOnlyFixture(File segmentStore,
org.apache.jackrabbit.oak.run.cli.FileStoreTarBuilderCustomizer builderCustomizer) |
static org.apache.jackrabbit.oak.run.cli.NodeStoreFixture |
getReadWriteFixture(File segmentStore,
org.apache.jackrabbit.oak.run.cli.FileStoreTarBuilderCustomizer builderCustomizer) |
static void |
initState(net.adamcin.oakpal.webster.WebsterPlan.Builder builder,
@NotNull javax.json.JsonObject planJson) |
static void |
installCndFromURL(javax.jcr.Session session,
URL... cnds) |
static void |
installPrivilegesFromURL(javax.jcr.Session session,
URL... privileges) |
static List<Map.Entry<org.apache.jackrabbit.spi.PrivilegeDefinition,net.adamcin.oakpal.api.Result<javax.jcr.security.Privilege>>> |
installPrivilegesWithIndivResults(javax.jcr.Session session,
URL... privileges) |
static void |
prepareRepo(File repoDir,
TestUtil.SessionStrategy sessionStrategy) |
static void |
withInMemoryRepo(TestUtil.SessionStrategy sessionStrategy) |
static void |
withReadOnlyFixture(File segmentStore,
File globalStore,
TestUtil.SessionStrategy sessionStrategy) |
static void |
withReadOnlyFixture(File segmentStore,
TestUtil.SessionStrategy sessionStrategy) |
public static void closeRepo(javax.jcr.Repository repo)
public static void withInMemoryRepo(TestUtil.SessionStrategy sessionStrategy) throws Exception
Exceptionpublic static void prepareRepo(File repoDir, TestUtil.SessionStrategy sessionStrategy) throws Exception
Exceptionpublic static org.apache.jackrabbit.oak.run.cli.NodeStoreFixture getReadWriteFixture(File segmentStore, org.apache.jackrabbit.oak.run.cli.FileStoreTarBuilderCustomizer builderCustomizer) throws Exception
Exceptionpublic static org.apache.jackrabbit.oak.run.cli.NodeStoreFixture getReadOnlyFixture(File segmentStore, org.apache.jackrabbit.oak.run.cli.FileStoreTarBuilderCustomizer builderCustomizer) throws Exception
Exceptionpublic static void compositeWithFixture(@NotNull
@NotNull org.apache.jackrabbit.oak.run.cli.NodeStoreFixture fixture,
@NotNull
@NotNull TestUtil.SessionStrategy sessionStrategy)
throws Exception
Exceptionpublic static void compositeWithFixtures(@NotNull
@NotNull org.apache.jackrabbit.oak.run.cli.NodeStoreFixture fixture,
@NotNull
@NotNull org.apache.jackrabbit.oak.run.cli.NodeStoreFixture globalFixture,
@NotNull
@NotNull TestUtil.SessionStrategy sessionStrategy)
throws Exception
Exceptionpublic static void withReadOnlyFixture(File segmentStore, File globalStore, TestUtil.SessionStrategy sessionStrategy) throws Exception
Exceptionpublic static void withReadOnlyFixture(File segmentStore, TestUtil.SessionStrategy sessionStrategy) throws Exception
Exceptionpublic static void installCndFromURL(javax.jcr.Session session,
URL... cnds)
throws javax.jcr.RepositoryException,
IOException,
org.apache.jackrabbit.commons.cnd.ParseException
javax.jcr.RepositoryExceptionIOExceptionorg.apache.jackrabbit.commons.cnd.ParseExceptionpublic static List<Map.Entry<org.apache.jackrabbit.spi.PrivilegeDefinition,net.adamcin.oakpal.api.Result<javax.jcr.security.Privilege>>> installPrivilegesWithIndivResults(javax.jcr.Session session, URL... privileges) throws javax.jcr.RepositoryException
javax.jcr.RepositoryExceptionpublic static void installPrivilegesFromURL(javax.jcr.Session session,
URL... privileges)
throws javax.jcr.RepositoryException,
IOException,
org.apache.jackrabbit.spi.commons.privilege.ParseException
javax.jcr.RepositoryExceptionIOExceptionorg.apache.jackrabbit.spi.commons.privilege.ParseExceptionpublic static void assertFileContains(@NotNull
@NotNull File haystack,
@NotNull
@NotNull String needle)
throws Exception
Exceptionpublic static net.adamcin.oakpal.core.OakMachine.Builder fromPlan(@NotNull
@NotNull javax.json.JsonObject planJson)
throws Exception
ExceptionCopyright © 2017–2020. All rights reserved.