【发布时间】:2018-10-19 22:10:06
【问题描述】:
我希望能够查看我的代码中 reactive({...}) 部分内部发生的情况。我认为使用 shinytest 可能是一种执行我的应用程序部分的方法,这些应用程序使用 Shiny Modules 并了解 callModule。
我在我的代码中尝试了以下记录/跟踪/打印。
print("hello1")
message("hello2")
cat(file=stderr(), "hello3")
logging::loginfo("hello4")
runtest.R
library(shinytest)
testApp("/home/eddy/rwork/filters", "mytest")
viewTestDiff("/home/eddy/rwork/filters", interactive = FALSE)
输出:
Rscript runtest.R
Running mytest.R
==== Comparing mytest... No changes.
==== mytest ====
No differences between expected and current results
如何在测试运行中添加一些跟踪输出?
【问题讨论】: