Skip to content

Update test #3

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 4 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
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
Original file line number Diff line number Diff line change
Expand Up @@ -21,15 +21,14 @@ test_that("The plot is correctly facetted based on a variable", {
visit = c(1, 2, 1, 2),
statMean = rnorm(4)
)

expect_silent(
gg <- subjectProfileSummaryPlot(
data = summaryTable,
xVar = "visit",
facetVar = "PARAM"
)

gg <- subjectProfileSummaryPlot(
data = summaryTable,
xVar = "visit",
facetVar = "PARAM"
)

expect_s3_class(gg, "ggplot2")

# check that the plots is facetted
# and that facetted are ordered according to levels of factor
ggData <- lapply(ggplot_build(gg)$data, `[`, c("x", "y", "PANEL"))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -352,12 +352,18 @@ test_that("The size of the points (in the legend) is correctly set", {
colorVar = "TRT",
pointSize = pointSize
)

expect_equal(
object = gg$guides$colour$override.aes$size,
expected = pointSize
)


if (!inherits(ggplot2::guide_none(), "Guide")) {
expect_equal(
object = gg$guides$colour$override.aes$size,
expected = pointSize
)
} else {
expect_equal(
object = gg$guides$guides$colour$params$override.aes$size,
expected = pointSize
)
}
})

test_that("The variable labels are correctly extracted from the labels of all variables", {
Expand Down