[pygobject] tests: Fix test_torture_profile to return a number from its callback



commit a329f559002f2be0898309c9d81cdf2c34aef158
Author: Simon Feltman <sfeltman src gnome org>
Date:   Tue Jan 14 10:15:53 2014 -0800

    tests: Fix test_torture_profile to return a number from its callback
    
    Return a number from rather than None from the callback passed to
    regress_test_torture_signature_2. This fixes a TypeError being raised in
    callback return argument marshaling which was ignored by the test suite.

 tests/test_everything.py |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/tests/test_everything.py b/tests/test_everything.py
index 5e58fbc..0cd1804 100644
--- a/tests/test_everything.py
+++ b/tests/test_everything.py
@@ -1186,7 +1186,7 @@ class TestTortureProfile(unittest.TestCase):
         sys.stdout.write("\ttorture test 4 (10000 iterations): ")
 
         def callback(userdata):
-            pass
+            return 0
 
         userdata = [1, 2, 3, 4]
         start_time = time.clock()


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]