##// END OF EJS Templates
Added tests for displayhook...
Added tests for displayhook Work in progress. Tests will fail but we will fix them.

File last commit:

r21420:be0a8e6a
r21420:be0a8e6a
Show More
test_displayhook.py
19 lines | 538 B | text/x-python | PythonLexer
from IPython.testing.tools import AssertPrints, AssertNotPrints
def test_output_displayed():
"""Checking to make sure that output is displayed"""
with AssertPrints('2'):
ip.run_cell('1+1')
with AssertPrints('2'):
ip.run_cell('1+1 # comment with a semicolon;')
def test_output_quiet():
"""Checking to make sure that output is quiet"""
with AssertNotPrints('2'):
ip.run_cell('1+1;')
with AssertNotPrints('2'):
ip.run_cell('1+1; # comment with a semicolon')