def test_timeit_invalid_return():
    with nt.assert_raises_regex(SyntaxError, 'outside function'):
        _ip.run_line_magic('timeit', 'return')
def test_timeit_invalid_return():
    with nt.assert_raises_regex(SyntaxError, 'outside function'):
        _ip.run_line_magic('timeit', 'return')