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

    https://github.com/apache/spark/pull/17987#discussion_r116531475
  
    --- Diff: core/src/test/scala/org/apache/spark/SparkContextSuite.scala ---
    @@ -301,13 +301,13 @@ class SparkContextSuite extends SparkFunSuite with 
LocalSparkContext with Eventu
         sc = new SparkContext(new 
SparkConf().setAppName("test").setMaster("local"))
         sc.addJar(tmpJar.getAbsolutePath)
     
    -    // Invaid jar path will only print the error log, will not add to file 
server.
    +    // Invalid jar path will only print the error log, will not add to 
file server.
         sc.addJar("dummy.jar")
         sc.addJar("")
         sc.addJar(tmpDir.getAbsolutePath)
     
    -    sc.listJars().size should be (1)
    -    sc.listJars().head should include (tmpJar.getName)
    +    assert(sc.listJars().size == 1)
    --- End diff --
    
    This gives a better error message.
    
    **Before**
    
    ```
    2 was not equal to 1 (SparkContextSuite.scala:309)
    ```
    
    **After**
    
    ```
    
ArrayBuffer("spark://172.24.17.81:2411/jars/spark-7e45e7da-ca1b-4e33-8a64-1fb44860ee76",
 "spark://172.24.17.81:2411/jars/test7132431731623035882.jar") had size 2 
instead of expected size 1 (SparkContextSuite.scala:309)
    ```


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