Skip to content

Commit

Permalink
Module's ui functions are only checked to have the id parameter.
Browse files Browse the repository at this point in the history
All other parameters are not checked and are silently swallowed by ...
  • Loading branch information
llrs-roche committed Nov 12, 2024
1 parent a1645ec commit 6fd1a37
Showing 1 changed file with 0 additions and 5 deletions.
5 changes: 0 additions & 5 deletions tests/testthat/test-modules.R
Original file line number Diff line number Diff line change
Expand Up @@ -70,11 +70,6 @@ testthat::test_that("module requires ui_args argument to be a list", {
testthat::expect_error(module(ui_args = list(1, 2, 3)), "Must have names")
})

testthat::test_that("module throws when ui has data or datasets argument", {
testthat::expect_error(module(ui = function(id, data) NULL))
testthat::expect_error(module(ui = function(id, datasets) NULL))
})

testthat::test_that("module expects ui being a shiny ui module with any argument", {
testthat::expect_no_error(module(ui = function(id) NULL))
testthat::expect_no_error(module(ui = function(id, any_argument) NULL))
Expand Down

0 comments on commit 6fd1a37

Please sign in to comment.