Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 540f14c commit 3db734fCopy full SHA for 3db734f
1 file changed
lib/matplotlib/tests/test_widgets.py
@@ -343,15 +343,18 @@ def test_TextBox():
343
tool = widgets.TextBox(ax, 'Evaluate')
344
tool.on_submit(submit_event)
345
tool.on_text_change(text_change_event)
346
- tool.set_val('x**2')
+ tool.set_val('')
347
348
- assert tool.text == 'x**2'
+ assert tool.text == ''
349
assert text_change_event.call_count == 1
350
351
tool.begin_typing(tool.text)
352
tool.stop_typing()
353
-
+ do_event(tool, '_click')
354
+
355
assert submit_event.call_count == 2
356
357
+ tool.set_val('x**2')
358
do_event(tool, '_click')
359
do_event(tool, '_keypress', key='+')
360
do_event(tool, '_keypress', key='5')
0 commit comments