File tree Expand file tree Collapse file tree 2 files changed +23
-0
lines changed
tests/playwright/shiny/components/chat/dynamic_ui Expand file tree Collapse file tree 2 files changed +23
-0
lines changed Original file line number Diff line number Diff line change 1+ from shiny .express import render , ui
2+
3+ chat = ui .Chat (id = "chat" )
4+
5+
6+ @render .ui
7+ def chat_output ():
8+ return chat .ui (messages = ["A starting message" ])
Original file line number Diff line number Diff line change 1+ from playwright .sync_api import Page , expect
2+ from utils .deploy_utils import skip_on_webkit
3+
4+ from shiny .playwright import controller
5+ from shiny .run import ShinyAppProc
6+
7+
8+ @skip_on_webkit
9+ def test_validate_chat_basic (page : Page , local_app : ShinyAppProc ) -> None :
10+ page .goto (local_app .url )
11+
12+ chat = controller .Chat (page , "chat" )
13+
14+ expect (chat .loc ).to_be_visible (timeout = 30 * 1000 )
15+ chat .expect_latest_message ("A starting message" , timeout = 30 * 1000 )
You can’t perform that action at this time.
0 commit comments