Skip to content
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

Multitest #6

Merged
merged 6 commits into from
Sep 10, 2021
Merged

Multitest #6

merged 6 commits into from
Sep 10, 2021

Conversation

curadomr
Copy link
Contributor

@curadomr curadomr commented Sep 1, 2021

Implementation of multitest functionality (work-in-progress) : support for plotType = "multitest" to make test results data available for custom plotting functions

Rocha Curado added 2 commits August 26, 2021 17:01
- plotStudy checks modified to incorporate multiple tests
- getPlottingData modified (multiple test results are provided as list)
- addPlots @param modified to incorporate the "multiTest" entry
- getPlottingData @return modified to indicate output for multiple tests

man files updated accordingly. Tinytests were not
- new plots are provided for tinytest, one for plotType = "multiTest", called "plotMultiTest_sf", and one for  plotType = c("multiFeature", "multiTest"), called "plotMultiTest_mf".
- new tinytest sections created: "plotStudy (multitest)" and "getPlottingData (package, multitest)"
- vignettes updated to indicate possibility of multiple testIDs
@jdblischak
Copy link
Contributor

Thanks @curadomr!

Note this is a follow-up to PR #5

Copy link
Contributor

@jdblischak jdblischak left a comment

Choose a reason for hiding this comment

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

Looking good. The first major thing to fix is removing gather() to see if the jobs will pass then

R/tests.R Outdated Show resolved Hide resolved
inst/tinytest/testPlot.R Outdated Show resolved Hide resolved
@curadomr
Copy link
Contributor Author

curadomr commented Sep 7, 2021 via email

@jdblischak
Copy link
Contributor

The failing test is this one:

expect_identical_xl(
vapply(studies[[1]][["plots"]][[1]][["plots"]],
function(x) x[["plotType"]], character(1)),
c("singleFeature", "multiFeature")
)

The character(1) passed to vapply() means that each results should only be length 1. The new multiTest/multiFeature plot breaks this.

In general I think this simplistic test is no longer sufficient now that we have many more example custom plotting functions. Could you please delete that failing test and replace it with one test per plotting function? The first two are below:

expect_identical_xl(
  studies[[1]][["plots"]][[1]][["plots"]][[1]][["plotType"]],
  "singleFeature"
)

expect_identical_xl(
  studies[[1]][["plots"]][[1]][["plots"]][[2]][["plotType"]],
  "multiFeature"
)

# add similar tests for your multiTest plots here

Copy link
Contributor

@jdblischak jdblischak left a comment

Choose a reason for hiding this comment

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

The tests are passing! 🎉 I've made some minor suggestions for you to address. Thanks!

R/tests.R Outdated Show resolved Hide resolved
inst/tinytest/testApp.R Show resolved Hide resolved
R/tests.R Outdated Show resolved Hide resolved
@jdblischak jdblischak merged commit 8cbb7f8 into abbvie-external:main Sep 10, 2021
@jdblischak
Copy link
Contributor

Thanks @curadomr!

@curadomr curadomr deleted the multitest branch September 21, 2021 13:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants