##// END OF EJS Templates
test timeit quiet and return
Matthias BUSSONNIER -
Show More
@@ -487,7 +487,21 b' def test_timeit_special_syntax():'
487 # cell mode test
487 # cell mode test
488 _ip.run_cell_magic('timeit', '-n1 -r1', '%lmagic my line2')
488 _ip.run_cell_magic('timeit', '-n1 -r1', '%lmagic my line2')
489 nt.assert_equal(_ip.user_ns['lmagic_out'], 'my line2')
489 nt.assert_equal(_ip.user_ns['lmagic_out'], 'my line2')
490
490
491 def test_timeit_return():
492 """
493 test wether timeit -o return object
494 """
495
496 res = _ip.run_line_magic('timeit','-n10 -r10 -o 1')
497 assert(res is not None)
498
499 def test_timeit_quiet():
500 """
501 test quiet option of timeit magic
502 """
503 with tt.AssertNotPrints("loops"):
504 _ip.run_cell("%timeit -n1 -r1 -q 1")
491
505
492 @dec.skipif(execution.profile is None)
506 @dec.skipif(execution.profile is None)
493 def test_prun_special_syntax():
507 def test_prun_special_syntax():
General Comments 0
You need to be logged in to leave comments. Login now