Format: application/x-python-code
⬇ Download File (1.7 KB)
   1  o
   2  
   3  ��h��@s0dZddlmZddlmZdd�Zdd�ZdS)	ayThese kinds of tests are less than ideal, but at least they run.
   4  
   5  This was an old test that was being run interactively in the top-level tests/
   6  directory, which we are removing.  For now putting this here ensures at least
   7  we do run the test, though ultimately this functionality should all be tested
   8  with better-isolated tests that don't rely on the global instance in iptest.
   9  �)�LineInfo)�AutocallCheckercCsdS)a�
  10      In [1]: def f1(a,b,c):
  11         ...:     return a+b+c
  12         ...:
  13  
  14      In [2]: def f2(a):
  15         ...:     return a + a
  16         ...:
  17  
  18      In [3]: def r(x):
  19         ...:     return True
  20         ...:
  21  
  22      In [4]: ;f2 a b c
  23      Out[4]: 'a b ca b c'
  24  
  25      In [5]: assert _ == "a b ca b c"
  26  
  27      In [6]: ,f1 a b c
  28      Out[6]: 'abc'
  29  
  30      In [7]: assert _ == 'abc'
  31  
  32      In [8]: print(_)
  33      abc
  34  
  35      In [9]: /f1 1,2,3
  36      Out[9]: 6
  37  
  38      In [10]: assert _ == 6
  39  
  40      In [11]: /f2 4
  41      Out[11]: 8
  42  
  43      In [12]: assert _ == 8
  44  
  45      In [12]: del f1, f2
  46  
  47      In [13]: ,r a
  48      Out[13]: True
  49  
  50      In [14]: assert _ == True
  51  
  52      In [15]: r'a'
  53      Out[15]: 'a'
  54  
  55      In [16]: assert _ == 'a'
  56      N�rrr�Vc:\Users\shubh\Videos\agent\nova\Lib\site-packages\IPython/core/tests/test_autocall.py�doctest_autocall
  57  srcCs6td�}tj}t|j||jd�}|�|�dusJ�dS)Nzr'a')�shell�prefilter_manager�config)r�iprrrr	�check)Z	line_info�pm�acrrr�'test_autocall_should_ignore_raw_strings@srN)�__doc__ZIPython.core.splitinputrZIPython.core.prefilterrrrrrrr�<module>s
  58  3