Re: Problem with doctest

2020-05-04 Thread Dieter Maurer
ast wrote at 2020-5-4 15:20 +0200: >doctest of the sample function funct() doesn't works >because flag used by funct() is the one defined in >first line "flag = True" and not the one in the >doctest code ">>> flag = False". > >Any work around known ? > > >flag = True # <- funct() alway

Re: Problem with doctest

2020-05-04 Thread Peter Otten
Unknown wrote: > Hello > > doctest of the sample function funct() doesn't works > because flag used by funct() is the one defined in > first line "flag = True" and not the one in the > doctest code ">>> flag = False". > > Any work around known ? You can import the module where funct() is define