Github user pnowojski commented on a diff in the pull request:

    https://github.com/apache/flink/pull/6081#discussion_r195007487
  
    --- Diff: 
flink-streaming-java/src/test/java/org/apache/flink/streaming/runtime/tasks/StreamTaskTest.java
 ---
    @@ -806,6 +819,40 @@ public void testOperatorClosingBeforeStopRunning() 
throws Throwable {
                }
        }
     
    +   /**
    +    * Test set user code ClassLoader before calling ProcessingTimeCallback.
    +    */
    +   @Test
    +   public void testSetsUserCodeClassLoaderForTimerThreadFactory() throws 
Throwable {
    +           try (MockEnvironment mockEnvironment = new 
MockEnvironmentBuilder()
    +                   .setUserCodeClassLoader(new 
TestUserCodeClassLoader()).build()) {
    +                   TimeServiceTask timerServiceTask = spy(new 
TimeServiceTask(mockEnvironment));
    --- End diff --
    
    why do you need `spy` here?


---

Reply via email to