From f7241a7a9496d6e3f5fefcab0bd84884dc8ac1f5 Mon Sep 17 00:00:00 2001 From: Anna Rift Date: Fri, 4 Oct 2024 11:33:20 -0700 Subject: [PATCH] Use buildStdContext helper in domain tests Signed-off-by: Anna Rift --- frontend/test/resolution/testDomains.cpp | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/frontend/test/resolution/testDomains.cpp b/frontend/test/resolution/testDomains.cpp index 2fd7dcb26f7d..1e2d35d4d8fa 100644 --- a/frontend/test/resolution/testDomains.cpp +++ b/frontend/test/resolution/testDomains.cpp @@ -40,11 +40,8 @@ static void testRectangular(std::string domainType, int rank, std::string idxType, std::string strides) { - Context::Configuration config; - config.chplHome = getenv("CHPL_HOME"); - Context ctx(config); - Context* context = &ctx; - setupModuleSearchPaths(context, false, false, {}, {}); + auto ctx = buildStdContext(); + auto context = ctx.get(); ErrorGuard guard(context); std::string program = @@ -379,11 +376,8 @@ static void testBadDomain(std::string domainType) { // With standard modules { - Context::Configuration config; - config.chplHome = getenv("CHPL_HOME"); - Context ctx(config); - Context* context = &ctx; - setupModuleSearchPaths(context, false, false, {}, {}); + auto ctx = buildStdContext(); + auto context = ctx.get(); ErrorGuard guard(context); testBadDomainHelper(domainType, context, guard);