Skip to content

Commit 44bab51

Browse files
author
Gergely Pollak
committed
YARN-10849 Clarify testcase documentation for TestServiceAM#testContainersReleasedWhenPreLaunchFails. Contributed by Szilard Nemeth
1 parent 0ba6f35 commit 44bab51

File tree

1 file changed

+11
-3
lines changed
  • hadoop-yarn-project/hadoop-yarn/hadoop-yarn-applications/hadoop-yarn-services/hadoop-yarn-services-core/src/test/java/org/apache/hadoop/yarn/service

1 file changed

+11
-3
lines changed

hadoop-yarn-project/hadoop-yarn/hadoop-yarn-applications/hadoop-yarn-services/hadoop-yarn-services-core/src/test/java/org/apache/hadoop/yarn/service/TestServiceAM.java

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -480,9 +480,17 @@ public void testIPChange() throws TimeoutException,
480480
am.stop();
481481
}
482482

483-
// Test to verify that the containers are released and the
484-
// component instance is added to the pending queue when building the launch
485-
// context fails.
483+
/**
484+
This test verifies that the containers are released and the
485+
component instance is added to the pending queue when building the launch
486+
context fails.
487+
Here, we intentionally have an artifact that doesn't have an id.
488+
This will cause TarballProviderService.processArtifact
489+
to throw an IllegalArgumentException because the Path object is
490+
constructed from the id of the artifact.
491+
In case the id is set to null or unset so it is effectively null,
492+
Path.checkPathArg throws an IllegalArgumentException.
493+
**/
486494
@Test(timeout = 30000)
487495
public void testContainersReleasedWhenPreLaunchFails()
488496
throws Exception {

0 commit comments

Comments
 (0)