Github user sarutak commented on a diff in the pull request:
https://github.com/apache/spark/pull/10456#discussion_r48422480
--- Diff: core/src/test/scala/org/apache/spark/SparkContextSuite.scala ---
@@ -274,6 +274,31 @@ class SparkContextSuite extends SparkFunSuite with
LocalSparkContext {
}
}
+ test("Default path for file based RDDs is properly set (SPARK-12517)")
{
+ sc = new SparkContext(new
SparkConf().setAppName("test").setMaster("local"))
+
+ // Test filetextFile, wholeTextFiles, binaryFiles, hadoopFile and
+ // newAPIHadoopFile for setting the default path as the RDD name
+ val mockPath = "default/path/for/"
+
+ var targetPath = mockPath + "textFile"
+ assert(sc.textFile(targetPath).name == targetPath)
+
--- End diff --
Could you compare by `===` instead of `==` ?
We can get better error messages by `===` operator.
---
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]