Show More
@@ -59,7 +59,7 b' def flush_channels(kc=None):' | |||||
59 | except Empty: |
|
59 | except Empty: | |
60 | break |
|
60 | break | |
61 | else: |
|
61 | else: | |
62 |
|
|
62 | validate_message(msg) | |
63 |
|
63 | |||
64 |
|
64 | |||
65 | def execute(code='', kc=None, **kwargs): |
|
65 | def execute(code='', kc=None, **kwargs): | |
@@ -68,14 +68,14 b" def execute(code='', kc=None, **kwargs):" | |||||
68 | kc = KC |
|
68 | kc = KC | |
69 | msg_id = kc.execute(code=code, **kwargs) |
|
69 | msg_id = kc.execute(code=code, **kwargs) | |
70 | reply = kc.get_shell_msg(timeout=TIMEOUT) |
|
70 | reply = kc.get_shell_msg(timeout=TIMEOUT) | |
71 |
|
|
71 | validate_message(reply, 'execute_reply', msg_id) | |
72 | busy = kc.get_iopub_msg(timeout=TIMEOUT) |
|
72 | busy = kc.get_iopub_msg(timeout=TIMEOUT) | |
73 |
|
|
73 | validate_message(busy, 'status', msg_id) | |
74 | nt.assert_equal(busy['content']['execution_state'], 'busy') |
|
74 | nt.assert_equal(busy['content']['execution_state'], 'busy') | |
75 |
|
75 | |||
76 | if not kwargs.get('silent'): |
|
76 | if not kwargs.get('silent'): | |
77 | pyin = kc.get_iopub_msg(timeout=TIMEOUT) |
|
77 | pyin = kc.get_iopub_msg(timeout=TIMEOUT) | |
78 |
|
|
78 | validate_message(pyin, 'pyin', msg_id) | |
79 | nt.assert_equal(pyin['content']['code'], code) |
|
79 | nt.assert_equal(pyin['content']['code'], code) | |
80 |
|
80 | |||
81 | return msg_id, reply['content'] |
|
81 | return msg_id, reply['content'] |
General Comments 0
You need to be logged in to leave comments.
Login now