-
-
Notifications
You must be signed in to change notification settings - Fork 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
fix scheduled tests #201
fix scheduled tests #201
Conversation
Unit Tests Summary 1 files 11 suites 17s ⏱️ Results for commit 82c4311. ♻️ This comment has been updated with latest results. |
@@ -3,6 +3,7 @@ library(dplyr) | |||
# h_get_diagnostics ---- |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If the test skip check is added to every test in the file you could add it to the top of the file instead so it only needs to check once (this also applies to the other test files)!
# h_get_diagnostics ---- | |
skip_if_not_installed("TMB") | |
# h_get_diagnostics ---- |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i am testing this, i think this tmb package should be imported. rather than suggests actually. if true, I will remove all these lines
Do you really need the TMB conditions? mmrm needs TMB of course, but that should be resolved automatically through package dependencies, or not? |
import dont work either, after reading this more carefully
it's issue with omp, I will flag this with rhub about there image. |
ii also raised an issue at r-hub/containers#85 |
This reverts commit 2a9b55f.
Hi. I can see that this is passing without any adjustments to the workflow thus I reverted my changes. This is green now: https://github.com/insightsengineering/tern.mmrm/actions/runs/12907163492/job/35990040546 |
@@ -98,7 +98,7 @@ h_get_diagnostics <- function(fit) { | |||
#' | |||
#' @export | |||
#' | |||
#' @examples | |||
#' @examplesIf requireNamespace("TMB") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It looks like the standard applied in other packages is require()
. Both are fully functional and this is just for consistency
#' @examplesIf requireNamespace("TMB") | |
#' @examplesIf require("TMB", quietly = TRUE) |
@@ -3,6 +3,7 @@ library(dplyr) | |||
# h_get_diagnostics ---- | |||
|
|||
test_that("h_get_diagnostics works as expected", { | |||
testthat::skip_if_not(requireNamespace("TMB")) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
there is a dedicated function for this - also easier to follow
testthat::skip_if_not(requireNamespace("TMB")) | |
testthat::skip_if_not_installed("TMB") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TMB seem to be installed, but loading was off.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
in such case I would do skip-if-not-installed followed by explicit library to signal that the loading is what we are looking for
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tmb is in suggests though, it should implicitly included by mmrm package, and not by us. again, I think this is an image issue. i don't think this pr is good, and it is not solving the real issue
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tmb is in suggests though, it should implicitly included by mmrm package
Then all is needed is just skip if not installed. Following nosuggest logic, the package should remain fully functional without suggested pacakge
and not by us
Partially true - see above. I would say mmrm should specify the version - not here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
mmrm has specified it's version. we can ignore that line
I m rerunning this on main, and see if it works |
Signed-off-by: Joe Zhu <[email protected]>
Hey @shajoezhu - I just ran the rhub tests on that branch and it is all passing: https://github.com/insightsengineering/tern.mmrm/actions/runs/13334754421 |
hi @pawelru , yes, it is. let's have a catch-up next week. I think the branch's fix is trying to hide the problem rather than solving a real issue, I might be over thinking, but lets have a chat before merging this |
good. this PR is not needed. as main is passing. it is not our issue! |
yay! one of the many CRAN cases where waiting is best |
I agree! @danielinteractive :D |
Pull Request
Fixes #nnn