def test_ident(self): # Test sanity of _thread.get_ident() self.failUnless(isinstance(_thread.get_ident(), int), "_thread.get_ident() returned a non-integer") self.failUnless(_thread.get_ident() != 0, "_thread.get_ident() returned 0")
def queue_mark(queue, delay): """Wait for ``delay`` seconds and then put something into ``queue``""" time.sleep(delay) queue.put(_thread.get_ident())
def test_ident(self): #Test sanity of _thread.get_ident() self.assertIsInstance(_thread.get_ident(), int, "_thread.get_ident() returned a non-integer") self.assertTrue(_thread.get_ident() != 0, "_thread.get_ident() returned 0")
def test_ident(self): #Test sanity of _thread.get_ident() self.failUnless(isinstance(_thread.get_ident(), int), "_thread.get_ident() returned a non-integer") self.failUnless(_thread.get_ident() != 0, "_thread.get_ident() returned 0")