Chris Jerdonek added the comment: I would like to see this written in a way that would let one run it globally or on a single file independent of a patch (e.g. an independent script from which patchcheck could import certain functions). Or is that what you explicitly didn't want Éric? :)
This would let one do a report or global check as was done for issue 16056. It would also make it a bit easier to check manually that the script is checking for duplicates correctly. Also, some suggestions: +def testmethod_names(code, name=[]): It might be clearer to use the name=None form. + test_files = [fn for fn in python_files if + fn.startswith(os.path.join('Lib', 'test'))] Are you getting the test files in test/ subdirectories of subpackages? I think checking that the file name starts with "test_" might be sufficient to get all test files. + if name[-1].startswith('test_'): I believe 'test' is the prefix that unittest uses. I'm pretty sure we have some tests that don't start with 'test_'. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue16079> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com