Skip to content

Commit 2dcb671

Browse files
committed
Add shiny/examples e2e test
1 parent dc1f588 commit 2dcb671

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
from playwright.sync_api import Page, expect
2+
from conftest import ShinyAppProc, create_doc_example_fixture
3+
import controls
4+
5+
app = create_doc_example_fixture("input_numeric")
6+
7+
8+
def test_input_numeric(page: Page, app: ShinyAppProc) -> None:
9+
page.goto(app.url)
10+
11+
obs = controls.NumericInput(page, "obs")
12+
obs.expect.to_have_value("10")
13+
output = page.locator("#value")
14+
expect(output).to_have_text("10")
15+
16+
obs.loc.fill("21")
17+
obs.expect.to_have_value("21")
18+
expect(output).to_have_text("21")

0 commit comments

Comments
 (0)