Skip to content

Commit

Permalink
Set the option in the app itself
Browse files Browse the repository at this point in the history
  • Loading branch information
cpsievert committed Mar 20, 2024
1 parent f00fa71 commit 71a96da
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 7 deletions.
3 changes: 3 additions & 0 deletions inst/apps/126-async-ticks/app.R
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ library(promises)
library(future)
plan(multisession)

opts <- options(shiny.legacy.datatable = TRUE)
onStop(function() options(opts))

testForMissingRenderFunctions <- function() {
# If we add any render functions, they should be added to this test app. This test
# will make it obvious if we forget.
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
8 changes: 1 addition & 7 deletions inst/apps/126-async-ticks/tests/testthat/test-mytest.R
Original file line number Diff line number Diff line change
@@ -1,13 +1,7 @@
library(shinytest2)

test_that("Migrated shinytest test: mytest.R", {
app <- AppDriver$new(
variant = shinytest2::platform_variant(),
# Use legacy datatable implementation just for the
# info$datatable$colnames test below. We could, of course,
# update that test, but it's also good to test the legacy.
options = list(shiny.legacy.datatable = TRUE)
)
app <- AppDriver$new(variant = shinytest2::platform_variant())

app$expect_values()
app$expect_screenshot()
Expand Down

0 comments on commit 71a96da

Please sign in to comment.