tillrohrmann commented on a change in pull request #10076: 
[FLINK-14465][runtime] Let `StandaloneJobClusterEntrypoint` use user code class 
loader
URL: https://github.com/apache/flink/pull/10076#discussion_r342067144
 
 

 ##########
 File path: 
flink-container/src/test/java/org/apache/flink/container/entrypoint/ClassPathJobGraphRetrieverTest.java
 ##########
 @@ -160,6 +238,80 @@ public void testJarFromClassPathSupplier() throws 
IOException {
                assertThat(jarFiles, contains(file1, file2));
        }
 
+       @Test
+       public void testJobGraphRetrievalFailIfJobDirDoesNotHaveEntryClass() 
throws IOException {
+               final File testJar = TestJob.getTestJobJar();
+               final ClassPathJobGraphRetriever classPathJobGraphRetriever = 
new ClassPathJobGraphRetriever(
+                       new JobID(),
+                       SavepointRestoreSettings.none(),
+                       PROGRAM_ARGUMENTS,
+                       null,
+                       // only find the entry class from job dir
+                       () -> Collections.singleton(testJar),
+                       userDirHasNotEntryClass);
 
 Review comment:
   Should we maybe introduce a builder for the `ClassPathJobGraphRetriever` to 
give more expressive names and to better model which fields are optional 
(`jobClassName` and `jobDir`)?

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to