[SPARK-2710] [SQL] dead code removed, test suite added (based on JdbcRDDSuite in core rdd)