Commit Graph

4 Commits

Author SHA1 Message Date
Brian C. Lane 9d6211f1b3 Fix unclosed files
Python will eventually close open files, but it is recommended to
explicitly close them instead of waiting for the gc or program exit.

This fixes all the uses of open...read/write in the codebase, mostly in
tests.
2020-10-07 10:51:41 -07:00
Brian C. Lane d265824564 tests: unittest and pytest expect functions to start with test_ 2020-01-15 10:40:17 -08:00
Brian C. Lane 0708302464 Use binary mode to tail the file
In python 3 f.seek() on text doesn't work like it does in py2/C because
text is now unicode. So change read_tail to use byte mode and take
unicode into account. Also add tests for it.
2019-07-11 15:16:41 -07:00
Brian C. Lane cc69478249 tests: Add sysutils test 2018-11-12 11:13:37 -08:00