Commit Graph

10 Commits

Author SHA1 Message Date
Per A. Brodtkorb
e4e8bf8317 Fixes issue 1571:
Adding missing close for open.
If the "close()" call is missing after a "open(filename)" call, the filename isn't guaranteed to be closed before the interpreter exits.
This is generally a bad practice as explained here: https://stackoverflow.com/questions/7395542/is-explicitly-closing-files-important

Also replaced "fid=open(filename) fid.close()" statements for files with the safer
"with open(filename) as fid:" blocks. See https://www.python.org/dev/peps/pep-0343/
2020-03-23 17:16:44 +01:00
Robin Dunn
4b6ee40a14 Merge pull request #938 from RobinD42/fix-issue932-b
Restore wx.lib.pubsub, and officially deprecate
(cherry picked from commit 8fad2231a0)
2018-07-20 16:45:05 -07:00
Scott Talbert
b683d39ab2 Fix lib_pubsub_provider tests 2016-08-15 20:54:44 -04:00
Robin Dunn
bb01dc0d7f Use absolute import of wtc in the unittest modules, instead of depending on them being run as __main__ and getting the folder on the sys.path by default. 2016-06-30 16:49:19 -07:00
Robin Dunn
4f38ee259d Remove imp_unittest 2016-05-07 19:16:28 -07:00
Robin Dunn
09a9eae1ba Make the pubsub tests Py3 compatible
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@76021 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-02-26 03:54:09 +00:00
Robin Dunn
207c1f294c PR 68: update unit tests for pubsub
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@76020 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-02-26 03:53:59 +00:00
Robin Dunn
5077a51507 write temp file to unittests folder, and remove it when done
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@73911 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-05-04 02:00:44 +00:00
Robin Dunn
3105b4d95a Pubsub unittest updates from Werner
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@73903 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-05-02 01:01:30 +00:00
Robin Dunn
d0e440a304 Add pubsub unittests, adapted by Werner
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@73830 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-04-20 21:53:50 +00:00