Skip to contents

Populates the supplied session variable for testing.

Usage

DM_test_mksession(session = list())

Arguments

session

Shiny session variable (in app) or a list (outside of app)

Value

The DM portion of the `all_sess_res` returned from FM_app_preload

Examples

session = shiny::MockShinySession$new()
sess_res = DM_test_mksession(session=session)
#> → ASM: including file
#> → ASM:   source: file.path(system.file(package="onbrand"), "templates", "report.docx")
#> → ASM:   dest:   file.path("config","report.docx")
#> → ASM: including file
#> → ASM:   source: file.path(system.file(package="onbrand"), "templates", "report.pptx")
#> → ASM:   dest:   file.path("config","report.pptx")
#> → ASM: including file
#> → ASM:   source: file.path(system.file(package="onbrand"), "templates", "report.yaml")
#> → ASM:   dest:   file.path("config","report.yaml")
#> → ASM: State initialized
#> → ASM: setting word placeholders: 
#> → ASM:   -> setting docx ph: HEADERLEFT = left header
#> → ASM:   -> setting docx ph: HEADERRIGHT = right header
#> → ASM:   -> setting docx ph: FOOTERLEFT = left footer
#> → ASM: module isgood: TRUE
#> → DM: module checksum updated: f280116ab6b4488df6de76aff513a83f
#> → DM: State initialized
#> → DM: ds checksum updated: 641fcbc6616d24d05acded4317a3bb12
#> → DM: module checksum updated: 78099100dae67cc0fee50517ea72a920
#> → DM: adding preload sources
#> → DM:  - file added: TEST_DATA.xlsx
#> → DM: added: TEST_DATA.xlsx
#> → DM:  - url added: https://raw.githubusercontent.com/john-harrold/formods/refs/heads/master/inst/test_data/SDTM_PC.csv
#> → DM: url added: https://raw.githubusercontent.com/john-harrold/formods/refs/heads/master/inst/test_data/SDTM_PC.csv
#> → DM:  - url added: https://raw.githubusercontent.com/john-harrold/formods/refs/heads/master/inst/test_data/SDTM_EX.csv
#> → DM: url added: https://raw.githubusercontent.com/john-harrold/formods/refs/heads/master/inst/test_data/SDTM_EX.csv
#> → DM:  - url added: https://raw.githubusercontent.com/john-harrold/formods/refs/heads/master/inst/test_data/SDTM_DM.csv
#> → DM: url added: https://raw.githubusercontent.com/john-harrold/formods/refs/heads/master/inst/test_data/SDTM_DM.csv
#> → DM: loading element idx: 1
#> → DM: ds checksum updated: bdb7bd13194685fa5c00f236cc887e00
#> → DM: module checksum updated: 645c93487229cc013635dbcf55b5e50a
#> → DM: added element idx: 1
#> → DM: loading element idx: 2
#> → DM: ds checksum updated: cad45daa4a1529cd222b350cc0e0f300
#> → DM: module checksum updated: 30fefdb16c7f4bb3db965078732bb187
#> → DM: added element idx: 2
#> → DM: loading element idx: 3
#> → DM: ds checksum updated: 77dc92a25a3c5acf3b17c76abd9cf0c9
#> → DM: module checksum updated: 9bcde934f346fcee2f26bbe8d1a3059f
#> → DM: added element idx: 3
#> → DM: loading element idx: 4
#> → DM: ds checksum updated: 8f4ef4750cce7aab6d753b501c95c8bc
#> → DM: module checksum updated: 9399fb3f907c2edca788c22db2e945cf
#> → DM: added element idx: 4
#> → DM: module isgood: TRUE
#> → # preload_complete is good: TRUE ------------------------------------------