Skip to content

Commit

Permalink
Add test to check the R print method is doing something.
Browse files Browse the repository at this point in the history
  • Loading branch information
yanboliang committed Sep 18, 2016
1 parent 22365ef commit 1e5b6c2
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions R/pkg/inst/tests/testthat/test_mllib.R
Expand Up @@ -760,6 +760,7 @@ test_that("spark.kstest", {

expect_equal(stats$p.value, rStats$p.value, tolerance = 1e-4)
expect_equal(stats$statistic, unname(rStats$statistic), tolerance = 1e-4)
expect_true(length(capture.output(stats)) != 0)

testResult <- spark.kstest(df, "test", "norm", -0.5)
stats <- summary(testResult)
Expand All @@ -768,6 +769,7 @@ test_that("spark.kstest", {

expect_equal(stats$p.value, rStats$p.value, tolerance = 1e-4)
expect_equal(stats$statistic, unname(rStats$statistic), tolerance = 1e-4)
expect_true(length(capture.output(stats)) != 0)
})

sparkR.session.stop()

0 comments on commit 1e5b6c2

Please sign in to comment.