[issue1234674] filecmp.cmp's "shallow" option

Andrew Kubera report at bugs.python.org
Sun Jul 27 06:13:09 CEST 2014


Andrew Kubera added the comment:

Attached is a couple extra tests which run filecmp on two files with different content but the same length and relevant stat() info. This appears to successfully check if the shallow options works correctly. 

It uses time.sleep(1) to ensure the files start out with different creation times, checks that filecmp returns false, then sets the creation time with os.utime to ensure filecmp is true.

These tests currently run successfully on 3.5, so if there was an issue, it has been resolved.

----------
nosy: +Andrew.Kubera
versions:  -Python 2.7, Python 3.2, Python 3.3, Python 3.4
Added file: http://bugs.python.org/file36123/filecmp_extra_shallow_file_check.diff

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue1234674>
_______________________________________


More information about the Python-bugs-list mailing list