From de10a2090942bcdf7adff49c78410d0c2aa4bbfc Mon Sep 17 00:00:00 2001 From: Aziem Chawdhary Date: Thu, 14 Nov 2024 23:59:16 +0000 Subject: [PATCH] Exclude new repo from pct test builder --- .../java/compiled/testHelper/PureTestBuilderCompiled.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/legend-pure-runtime/legend-pure-runtime-java-engine-compiled/src/main/java/org/finos/legend/pure/runtime/java/compiled/testHelper/PureTestBuilderCompiled.java b/legend-pure-runtime/legend-pure-runtime-java-engine-compiled/src/main/java/org/finos/legend/pure/runtime/java/compiled/testHelper/PureTestBuilderCompiled.java index de406f0467..265384c764 100644 --- a/legend-pure-runtime/legend-pure-runtime-java-engine-compiled/src/main/java/org/finos/legend/pure/runtime/java/compiled/testHelper/PureTestBuilderCompiled.java +++ b/legend-pure-runtime/legend-pure-runtime-java-engine-compiled/src/main/java/org/finos/legend/pure/runtime/java/compiled/testHelper/PureTestBuilderCompiled.java @@ -23,6 +23,7 @@ import org.eclipse.collections.api.factory.Sets; import org.eclipse.collections.api.list.MutableList; import org.eclipse.collections.api.map.MutableMap; +import org.eclipse.collections.api.set.ImmutableSet; import org.eclipse.collections.api.set.MutableSet; import org.eclipse.collections.impl.utility.ArrayIterate; import org.finos.legend.pure.m3.exception.PureAssertFailException; @@ -56,6 +57,7 @@ import java.lang.reflect.InvocationTargetException; import java.lang.reflect.Method; import java.util.Objects; +import java.util.Set; import static org.finos.legend.pure.m3.pct.shared.PCTTools.isPCTTest; import static org.junit.Assert.fail; @@ -189,7 +191,8 @@ public static CompiledExecutionSupport getClassLoaderExecutionSupport() public static CompiledExecutionSupport getClassLoaderExecutionSupport(ClassLoader classLoader) { - RichIterable codeRepos = CodeRepositoryProviderHelper.findCodeRepositories().select(r -> !r.getName().equals("test_generic_repository") && !r.getName().equals("other_test_generic_repository")); + ImmutableSet testRepos = Sets.immutable.of("test_generic_repository", "other_test_generic_repository", "test_milestoning_repository"); + RichIterable codeRepos = CodeRepositoryProviderHelper.findCodeRepositories().select(r -> !testRepos.contains(r.getName())); return new CompiledExecutionSupport( new JavaCompilerState(null, classLoader), new CompiledProcessorSupport(classLoader, MetadataLazy.fromClassLoader(classLoader, codeRepos.collect(CodeRepository::getName)), Sets.mutable.empty()),