From e9445757dc1d734462b5fbc293f9c75ac8a30464 Mon Sep 17 00:00:00 2001 From: guojialiang Date: Thu, 14 Aug 2025 20:41:33 +0800 Subject: [PATCH] fix flaky CopyProcessorTests Signed-off-by: guojialiang --- .../java/org/opensearch/ingest/common/CopyProcessorTests.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/ingest-common/src/test/java/org/opensearch/ingest/common/CopyProcessorTests.java b/modules/ingest-common/src/test/java/org/opensearch/ingest/common/CopyProcessorTests.java index b53ce2db994a8..631d342d504d0 100644 --- a/modules/ingest-common/src/test/java/org/opensearch/ingest/common/CopyProcessorTests.java +++ b/modules/ingest-common/src/test/java/org/opensearch/ingest/common/CopyProcessorTests.java @@ -48,7 +48,7 @@ public void testCopyExistingField() throws Exception { public void testCopyWithIgnoreMissing() throws Exception { IngestDocument ingestDocument = RandomDocumentPicks.randomIngestDocument(random()); - String targetFieldName = RandomDocumentPicks.randomFieldName(random()); + String targetFieldName = RandomDocumentPicks.randomNonExistingFieldName(random(), ingestDocument); Processor processor = createCopyProcessor("non-existing-field", targetFieldName, false, false, false); assertThrows( "source field [non-existing-field] doesn't exist",