You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This should print out an empty string, but instead, it prints Hello. Removing pyfakefs, the correct behavior is observed. I separately observed this bug with the pytest fixture, as well.
Your enviroment
Darwin-19.6.0-x86_64-i386-64bit
Python 3.6.5 (default, May 18 2020, 15:15:10)
[GCC 4.2.1 Compatible Apple LLVM 11.0.3 (clang-1103.0.32.59)]
pyfakefs 4.1.0
The text was updated successfully, but these errors were encountered:
Thanks! I have to admit that I was ignorant of os.truncate (never used it myself), and pyfakefs has the same problem... This has not been implemented, and apparantly has not been noticed so far.
Describe the bug
When calling
os.truncate
on a file that has been created in the fakefs, the contents are left unchangedHow To Reproduce
This should print out an empty string, but instead, it prints
Hello
. Removingpyfakefs
, the correct behavior is observed. I separately observed this bug with the pytest fixture, as well.Your enviroment
The text was updated successfully, but these errors were encountered: