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

    https://github.com/apache/spark/pull/11487#discussion_r55147183
  
    --- Diff: 
sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/ScalaReflectionSuite.scala
 ---
    @@ -237,4 +241,45 @@ class ScalaReflectionSuite extends SparkFunSuite {
         assert(anyTypes.forall(!_.isPrimitive))
         assert(anyTypes === Seq(classOf[java.lang.Object], 
classOf[java.lang.Object]))
       }
    +
    +  private def testThreadSafetyFor(name: String)(exec: () => Any) = {
    +    test(s"thread safety of ${name}") {
    +      for (_ <- 0 until 100) {
    --- End diff --
    
    `(0 until 100).foreach`? probably just a matter of taste but it's 
symmetrical with your inner loop then.
    You can import `java.net.URLClassLoader`.
    It doesn't really seem like you need a method here; it took a moment to see 
there was a test in here.
    
    Maybe it's obvious to you but why do all these classes/methods need to be 
tested separately?
    
    And is this locking still safe in 2.11?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to