RunProfileState (Location<PsiMethod> @NotNull [] testMethods, Module module, RunConfiguration configuration, ExecutionEnvironment environment) { TestData data = ((TestNGConfiguration)configuration).getPersistantData(); data.setPatterns(collectMethodPatterns(testMethods)); data.TEST_OBJECT = TestType.PATTERN.type; return new TestNGRunnableState(environment, (TestNGConfiguration)configuration); }