From 322f3fb04d2bcfd08a271c04cbf63fd26bace0dc Mon Sep 17 00:00:00 2001 From: LilJing Date: Sat, 8 Nov 2025 02:40:24 -0500 Subject: [PATCH 1/2] update old expect_equal calls --- tests/testthat/test_plot.R | 36 +++++++++++++++++++++--------------- 1 file changed, 21 insertions(+), 15 deletions(-) diff --git a/tests/testthat/test_plot.R b/tests/testthat/test_plot.R index e5c2577..201bcab 100644 --- a/tests/testthat/test_plot.R +++ b/tests/testthat/test_plot.R @@ -24,9 +24,12 @@ test_that( ) plot1 <- plot(ice_fit1) - expect_equal(class(plot1), c("gg", "ggplot")) + expect_s3_class(plot1, "ggplot") }) +# ------------------------------------------------------------------------- + + test_that( "check different interventions", { @@ -49,7 +52,7 @@ test_that( ) plot2 <- plot(ice_fit2) - expect_equal(class(plot2), c("gg", "ggplot")) + expect_s3_class(plot2, "ggplot") }) test_that( @@ -74,7 +77,7 @@ test_that( ) plot3 <- plot(ice_fit3) - expect_equal(class(plot3), c("gg", "ggplot")) + expect_s3_class(plot3, "ggplot") }) test_that( @@ -101,7 +104,7 @@ test_that( ) plot4a <- plot(ice_fit4a) - expect_equal(class(plot4a), c("gg", "ggplot")) + expect_s3_class(plot4a, "ggplot") }) test_that( @@ -129,9 +132,12 @@ test_that( ) plot4b <- plot(ice_fit4b) - expect_equal(class(plot4b), c("gg", "ggplot")) + expect_s3_class(plot4b, "ggplot") }) +# ------------------------------------------------------------------------- + + test_that( "plot hazard-based pooled ICE - pooled-over-time hazard model", { @@ -158,7 +164,7 @@ test_that( ) plot4c <- plot(ice_fit4c) - expect_equal(class(plot4c), c("gg", "ggplot")) + expect_s3_class(plot4c, "ggplot") }) test_that( @@ -184,7 +190,7 @@ test_that( ) plot4d <- plot(ice_fit4d) - expect_equal(class(plot4d), c("gg", "ggplot")) + expect_s3_class(plot4d, "ggplot") }) test_that( @@ -212,7 +218,7 @@ test_that( ) plot4e <- plot(ice_fit4e) - expect_equal(class(plot4e), c("gg", "ggplot")) + expect_s3_class(plot4e, "ggplot") }) test_that( @@ -238,7 +244,7 @@ test_that( ) plot4f <- plot(ice_fit4f) - expect_equal(class(plot4f), c("gg", "ggplot")) + expect_s3_class(plot4f, "ggplot") }) test_that( @@ -267,7 +273,7 @@ test_that( ) plot4h <- plot(ice_fit4h) - expect_equal(class(plot4h), c("gg", "ggplot")) + expect_s3_class(plot4h, "ggplot") }) test_that( @@ -293,7 +299,7 @@ test_that( ) plot5a <- plot(ice_fit5a) - expect_equal(class(plot5a), c("gg", "ggplot")) + expect_s3_class(plot5a, "ggplot") }) test_that( @@ -319,7 +325,7 @@ test_that( ) plot5b <- plot(ice_fit5b) - expect_equal(class(plot5b), c("gg", "ggplot")) + expect_s3_class(plot5b, "ggplot") }) test_that( @@ -348,7 +354,7 @@ test_that( ) plot6a <- plot(ice_fit6a) - expect_equal(class(plot6a), c("gg", "ggplot")) + expect_s3_class(plot6a, "ggplot") }) test_that( @@ -375,7 +381,7 @@ test_that( ) plot6b <- plot(ice_fit6b) - expect_equal(class(plot6b), c("gg", "ggplot")) + expect_s3_class(plot6b, "ggplot") }) test_that( @@ -531,7 +537,7 @@ test_that( plots <- plot(ice_fit7a, ice_fit7b, ice_fit7c, ice_fit7d, ice_fit7e, ice_fit7f, ice_fit7g, ice_fit7h) - expect_equal(class(plots), c("gg", "ggplot")) + expect_s3_class(plots, "ggplot") }) From b5c6da3601b86152079fba886b82924cd8116781 Mon Sep 17 00:00:00 2001 From: LilJing Date: Sat, 8 Nov 2025 13:01:10 -0500 Subject: [PATCH 2/2] update CRAN badge --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index 2735b78..735bd66 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,7 @@ # gfoRmulaICE: Parametric Iterative Conditional Expectation G-Formula ![CRAN Version](https://www.r-pkg.org/badges/version/gfoRmulaICE) + [![CRAN_Status_Badge](https://www.r-pkg.org/badges/version/gfoRmulaICE)](https://cran.r-project.org/package=gfoRmulaICE) [![Lifecycle: stable](https://img.shields.io/badge/lifecycle-stable-brightgreen.svg)](https://lifecycle.r-lib.org/articles/stages.html#stable) [![R-CMD-check](https://github.com/CausalInference/gfoRmulaICE/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/CausalInference/gfoRmulaICE/actions/workflows/R-CMD-check.yaml) ![Downloads](https://cranlogs.r-pkg.org/badges/grand-total/gfoRmulaICE)