On 3/2/15 10:36 AM, john wrote:
On 03/02/2015 09:01 AM, Werner wrote:
I would also like to move all the "__main__" demo/test code in each
module to e.g. "dabo.demo.ui", then I would remove the "if __name__ ==
"__main__":" hack in each file, then use this test code as the base
for unittest.
Does this make sense or ....:)
Is there a reason not to keep the test in the module? other than you
don't like the hack? I always found the testing within each of the
modules a good thing. When I discovered issues I never used the demo
stuff. I always found the demo to be a pain to work in because of the
added code. I guess there is a performance penalty because of the added
code but like I said it sure made things easy to find issues.
To be clear, it isn't a hack to have 'if __name__ == "__main__"' block...
Paul
_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-dev
Searchable Archives: http://leafe.com/archives/search/dabo-dev
This message: http://leafe.com/archives/byMID/[email protected]