insightsengineering / teal

Exploratory Web Apps for Analyzing Clinical Trial Data
https://insightsengineering.github.io/teal/
Other
168 stars 33 forks source link

`shinytest2` test for `teal.widgets::plot_with_settings` #1179

Closed m7pr closed 3 months ago

m7pr commented 4 months ago

Part of #503

This is here only temporary. We might decide that tests for {teal.widgets} should leave in {teal.widgets} package repository.

gogonzo commented 3 months ago

We might decide that tests for {teal.widgets} should leave in {teal.widgets} package repository.

@m7pr I'm sure we should test teal.widgets stuff in teal.widgets using a simple shiny app (not teal)

m7pr commented 3 months ago

@gogonzo yes, will move to {teal.widgets}. We had a couple of PRs towards {teal} when we knew this might belong to other package. We started here as we were creating the TealAppDriver class in here. Will move and continue in {teal.widgets}.

m7pr commented 3 months ago

@m7pr I'm sure we should test teal.widgets stuff in teal.widgets using a simple shiny app (not teal)

Yeah, but TealAppDriver has a lot of functionalities (with a lot of our custom methods) that help testing. That's why I used simple teal app for testing.

gogonzo commented 3 months ago

Yeah, but TealAppDriver has a lot of functionalities (with a lot of our custom methods) that help testing. That's why I used simple teal app for testing.

Yup, but TealAppDriver is for teal apps and not for a teal-independent widget. Widget in any shiny app has is not included in any teal_module so it doesn't need most of the TealAppDriver stuff. shinytest2 is already used there.

m7pr commented 3 months ago

Coolio @gogonzo - will try to remove {teal} (TealAppDriver) dependency and will create functions for the methods from TealAppDriver that I would like to use in teal.widgets testing. Moving this to teal.widgets repository.

m7pr commented 3 months ago

{teal.widgets} repo draft https://github.com/insightsengineering/teal.widgets/pull/240