From 4214d112fb59b8c9257dde36bd93de7c28631f18 Mon Sep 17 00:00:00 2001 From: Gian Merlino Date: Wed, 21 Jan 2026 11:42:09 -0800 Subject: [PATCH] SegmentLocalCacheManagerConcurrencyTest: Use tempDir for temp files. The tests should use temporary directories rather than the current working directory. --- .../loading/SegmentLocalCacheManagerConcurrencyTest.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/server/src/test/java/org/apache/druid/segment/loading/SegmentLocalCacheManagerConcurrencyTest.java b/server/src/test/java/org/apache/druid/segment/loading/SegmentLocalCacheManagerConcurrencyTest.java index 94a224e3a04f..1ba6969e934f 100644 --- a/server/src/test/java/org/apache/druid/segment/loading/SegmentLocalCacheManagerConcurrencyTest.java +++ b/server/src/test/java/org/apache/druid/segment/loading/SegmentLocalCacheManagerConcurrencyTest.java @@ -255,7 +255,7 @@ public void testAcquireSegment() throws IOException, ExecutionException, Interru @Test public void testAcquireSegmentFailTooManySegments() throws IOException { - final File localStorageFolder = new File("local_storage_folder"); + final File localStorageFolder = new File(tempDir, "local_storage_folder"); final Interval interval = Intervals.of("2019-01-01/P1D"); makeSegmentsToLoad(20, localStorageFolder, interval, segmentsToLoad); @@ -281,7 +281,7 @@ public void testAcquireSegmentFailTooManySegments() throws IOException @Test public void testAcquireSegmentBulkFailTooManySegments() throws IOException { - final File localStorageFolder = new File("local_storage_folder"); + final File localStorageFolder = new File(tempDir, "local_storage_folder"); final Interval interval = Intervals.of("2019-01-01/P1D"); makeSegmentsToLoad(30, localStorageFolder, interval, segmentsToLoad);