MCPcopy Create free account
hub / github.com/cztomczak/cefpython / test_multiple_callbacks

Method test_multiple_callbacks

examples/tutorial.py:189–196  ·  view source on GitHub ↗

Test both javascript and python callbacks.

(self, js_callback)

Source from the content-addressed store, hash-verified

187 self.browser = browser
188
189 def test_multiple_callbacks(self, js_callback):
190 """Test both javascript and python callbacks."""
191 js_print(self.browser, "Python", "test_multiple_callbacks",
192 "Called from Javascript. Will call Javascript callback now.")
193
194 def py_callback(msg_from_js):
195 js_print(self.browser, "Python", "py_callback", msg_from_js)
196 js_callback.Call("String sent from Python", py_callback)
197
198
199if __name__ == '__main__':

Callers

nothing calls this directly

Calls 1

js_printFunction · 0.85

Tested by

no test coverage detected