aljoscha commented on a change in pull request #10874: [FLINK-15552][table api] 
parameters --library and --jar doesn't work for DDL in sqlClient
URL: https://github.com/apache/flink/pull/10874#discussion_r369556795
 
 

 ##########
 File path: 
flink-scala-shell/src/test/scala/org/apache/flink/api/scala/ScalaShellITCase.scala
 ##########
 @@ -43,6 +43,13 @@ class ScalaShellITCase extends TestLogger {
   @Rule
   def temporaryFolder = _temporaryFolder
 
+  @After
+  def resetClassLoder(): Unit = {
+    // The Scala interpreter changes current class loader to ScalaClassLoader 
in every execution
+    // refer to [[ILoop.process()]]. So, we need reset it to original class 
loader after every Test.
+    
Thread.currentThread().setContextClassLoader(classOf[ScalaShellITCase].getClassLoader)
 
 Review comment:
   The basic change makes sense, yes. But why doesn't it work if we only reset 
it after all tests? Is it because there are multiple tests where the scala 
shell test uses the table environment?

----------------------------------------------------------------
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