aboutsummaryrefslogtreecommitdiff
path: root/R
diff options
context:
space:
mode:
Diffstat (limited to 'R')
-rw-r--r--R/pkg/R/DataFrame.R2
-rw-r--r--R/pkg/inst/tests/test_sparkSQL.R2
2 files changed, 2 insertions, 2 deletions
diff --git a/R/pkg/R/DataFrame.R b/R/pkg/R/DataFrame.R
index b59b700af5..841e77e55e 100644
--- a/R/pkg/R/DataFrame.R
+++ b/R/pkg/R/DataFrame.R
@@ -167,7 +167,7 @@ setMethod("isLocal",
setMethod("showDF",
signature(x = "DataFrame"),
function(x, numRows = 20) {
- cat(callJMethod(x@sdf, "showString", numToInt(numRows)), "\n")
+ callJMethod(x@sdf, "showString", numToInt(numRows))
})
#' show
diff --git a/R/pkg/inst/tests/test_sparkSQL.R b/R/pkg/inst/tests/test_sparkSQL.R
index af7a6c5820..f82e56fdd8 100644
--- a/R/pkg/inst/tests/test_sparkSQL.R
+++ b/R/pkg/inst/tests/test_sparkSQL.R
@@ -641,7 +641,7 @@ test_that("toJSON() returns an RDD of the correct values", {
test_that("showDF()", {
df <- jsonFile(sqlCtx, jsonPath)
- expect_output(showDF(df), "age name \nnull Michael\n30 Andy \n19 Justin ")
+ expect_output(showDF(df), "+----+-------+\n| age| name|\n+----+-------+\n|null|Michael|\n| 30| Andy|\n| 19| Justin|\n+----+-------+\n")
})
test_that("isLocal()", {