Skip to content
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
disable run bucketBy saveAsTable in pyspark doctest
  • Loading branch information
felixcheung committed May 10, 2017
commit 8890b60de7b94b97b9d87560cbb06faa8a838bf3
1 change: 1 addition & 0 deletions R/pkg/inst/tests/testthat/test_sparkSQL.R
Original file line number Diff line number Diff line change
Expand Up @@ -678,6 +678,7 @@ test_that("jsonRDD() on a RDD with json string", {

test_that("test tableNames and tables", {
count <- count(listTables())
expect_equal(count, 0)

df <- read.json(jsonPath)
createOrReplaceTempView(df, "table1")
Expand Down
4 changes: 2 additions & 2 deletions python/pyspark/sql/readwriter.py
Original file line number Diff line number Diff line change
Expand Up @@ -575,7 +575,7 @@ def bucketBy(self, numBuckets, col, *cols):
.. note:: Applicable for file-based data sources in combination with
:py:meth:`DataFrameWriter.saveAsTable`.

>>> (df.write.format('parquet')
>>> (df.write.format('parquet') # doctest: +SKIP
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Glad to know it. : ) For multi-line commands, we just need to do it in the first line?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

only the line with >>>

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

... .bucketBy(100, 'year', 'month')
... .mode("overwrite")
... .saveAsTable('bucketed_table'))
Expand All @@ -602,7 +602,7 @@ def sortBy(self, col, *cols):
:param col: a name of a column, or a list of names.
:param cols: additional names (optional). If `col` is a list it should be empty.

>>> (df.write.format('parquet')
>>> (df.write.format('parquet') # doctest: +SKIP
... .bucketBy(100, 'year', 'month')
... .sortBy('day')
... .mode("overwrite")
Expand Down