Class NewEnvTestRule

Object
com.liferay.portal.kernel.test.rule.NewEnvTestRule
All Implemented Interfaces:
org.junit.rules.TestRule
Direct Known Subclasses:
AspectJNewEnvTestRule

public class NewEnvTestRule extends Object implements org.junit.rules.TestRule
Author:
Shuyang Zhou
  • Field Details

    • INSTANCE

      public static final NewEnvTestRule INSTANCE
    • CLASS_PATH

      protected static final String CLASS_PATH
  • Constructor Details

    • NewEnvTestRule

      protected NewEnvTestRule()
  • Method Details

    • apply

      public org.junit.runners.model.Statement apply(org.junit.runners.model.Statement statement, org.junit.runner.Description description)
      Specified by:
      apply in interface org.junit.rules.TestRule
    • attachProcess

      protected static void attachProcess(String message)
    • getMethodKeys

      protected static List<com.liferay.portal.kernel.util.MethodKey> getMethodKeys(Class<?> targetClass, Class<? extends Annotation> annotationClass)
    • invoke

      protected static void invoke(ClassLoader classLoader, com.liferay.portal.kernel.util.MethodKey methodKey, Object object) throws Exception
      Throws:
      Exception
    • createArguments

      protected List<String> createArguments(org.junit.runner.Description description)
    • createClassLoader

      protected ClassLoader createClassLoader(org.junit.runner.Description description)
    • findNewEnv

      protected NewEnv findNewEnv(org.junit.runner.Description description)
    • processEnvironmentVariables

      protected Map<String,String> processEnvironmentVariables(String[] variables)
    • processJVMArgsLine

      protected List<String> processJVMArgsLine(NewEnv.JVMArgsLine jvmArgsLine)
    • processProcessCallable

      protected com.liferay.petra.process.ProcessCallable<Serializable> processProcessCallable(com.liferay.petra.process.ProcessCallable<Serializable> processCallable, com.liferay.portal.kernel.util.MethodKey testMethodKey)
    • resolveSystemProperty

      protected String resolveSystemProperty(String value)
    • setEnvironment

      protected void setEnvironment(com.liferay.petra.process.ProcessConfig.Builder builder, org.junit.runner.Description description)