GitHub user nkronenfeld opened a pull request: https://github.com/apache/spark/pull/19529
Support alternative unit testing styles in external applications ## What changes were proposed in this pull request? Support unit tests of external code (i.e., applications that use spark) using scalatest that don't want to use FunSuite. SharedSparkContext already supports this, but SharedSQLContext does not. I've introduced SharedSparkSession as a parent to SharedSQLContext, written in a way that it does support all scalatest styles. ## How was this patch tested? There are three new unit test suites added that just test using FunSpec, FlatSpec, and WordSpec. You can merge this pull request into a Git repository by running: $ git pull https://github.com/nkronenfeld/spark alternative-style-tests-2 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/spark/pull/19529.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #19529 ---- commit b9d41cd79f05f6c420d070ad07cdfa8f853fd461 Author: Nathan Kronenfeld <nicole.ore...@gmail.com> Date: 2017-10-15T03:04:16Z Separate out the portion of SharedSQLContext that requires a FunSuite from the part that works with just any old test suite. commit 0d4bd97247a2d083c7de55663703b38a34298c9c Author: Nathan Kronenfeld <nicole.ore...@gmail.com> Date: 2017-10-15T15:57:09Z Fix typo in trait name commit 83c44f1c24619e906af48180d0aace38587aa88d Author: Nathan Kronenfeld <nicole.ore...@gmail.com> Date: 2017-10-15T15:57:42Z Add simple tests for each non-FunSuite test style commit e460612ec6f36e62d8d21d88c2344378ecba581a Author: Nathan Kronenfeld <nicole.ore...@gmail.com> Date: 2017-10-15T16:20:44Z Document testing possibilities commit 0ee2aadf29b681b23bed356b14038525574204a5 Author: Nathan Kronenfeld <nicole.ore...@gmail.com> Date: 2017-10-18T23:46:44Z Better documentation of testing procedures commit 802a958b640067b99fda0b2c8587dea5b8000495 Author: Nathan Kronenfeld <nicole.ore...@gmail.com> Date: 2017-10-18T23:46:58Z Same initialization issue in SharedSparkContext as is in SharedSparkSession ---- --- --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org