Github user gatorsmile commented on the pull request:
https://github.com/apache/spark/pull/13337#issuecomment-222022807
Originally, `ListTableSuite` was added to test the API `tables` in
`SQLContext`
```Scala
def tables(databaseName: String): DataFrame = {
Dataset.ofRows(sparkSession, ShowTablesCommand(Some(databaseName),
None))
}
```
In `SparkSession`, we do not have such an API. Instead, I think the new way
for retrieving a list of tables is
[`spark.catalog.listTables`](https://github.com/apache/spark/blob/0f61d6efb45b9ee94fa663f67c4489fbdae2eded/sql/core/src/main/scala/org/apache/spark/sql/internal/CatalogImpl.scala#L85-L107).
This API has already been tested in the suite [`CatalogSuite.scala`
](https://github.com/apache/spark/blob/845e447fa03bf0a53ed79fa7e240af94dc152d2c/sql/core/src/test/scala/org/apache/spark/sql/internal/CatalogSuite.scala#L133-L174)
Basically, the only value of the test suite `ListTableSuite` is to verify
`tables` in `SQLContext`. Feel free to let me know if you want to remove it?
keep it? or modify it using the new API? Thanks!
---
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]