MCPcopy Index your code
hub / github.com/pywebio/PyWebIO / test

Function test

test/2.script_mode.py:22–38  ·  view source on GitHub ↗
(server_proc: subprocess.Popen, browser: Chrome)

Source from the content-addressed store, hash-verified

20
21
22def test(server_proc: subprocess.Popen, browser: Chrome):
23 template.test_output(browser)
24
25 time.sleep(1)
26
27 template.test_input(browser)
28
29 time.sleep(1)
30 template.save_output(browser, '2.script_mode.html',
31 # because tornado default bind ipv4 and ipv6 in script mode
32 process_func=lambda i: i.replace('::1', '127.0.0.1'))
33
34 browser.close()
35 time.sleep(3)
36
37 # script mode 下,此时 server 应停止
38 server_proc.wait(timeout=8)
39
40
41if __name__ == '__main__':

Callers

nothing calls this directly

Calls 1

closeMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…