From: zooko Date: Sat, 27 Jan 2007 02:17:59 +0000 (+0530) Subject: pyfec: execute tests on import of test_pyfec.py only if it is the __main__ X-Git-Url: https://git.rkrishnan.org/components/com_hotproperty/%22doc.html/rgr-080307.php?a=commitdiff_plain;h=0b05d0419790e2f517aa12cdc407c5855d73e80c;p=tahoe-lafs%2Fzfec.git pyfec: execute tests on import of test_pyfec.py only if it is the __main__ darcs-hash:83c9116fa21d29b701a52bf8033dce3f95bde461 --- diff --git a/pyfec/fec/test/test_pyfec.py b/pyfec/fec/test/test_pyfec.py index b01a3e6..00f59fb 100755 --- a/pyfec/fec/test/test_pyfec.py +++ b/pyfec/fec/test/test_pyfec.py @@ -83,5 +83,7 @@ def test_random(): _test_random() # sys.stdout.write(".") print "%d randomized tests pass." % (i+1) -test_random() + +if __name__ == "__init__": + test_random()