Exemple #1
0
def test_wait_callback_fail():
    try:
        set_wait_callback(1)
        assert False
    except TypeError:
        assert True
    except:
        assert False
Exemple #2
0
def test_wait_callback():
    def callback(fd, state):
        print fd, state

    set_wait_callback(callback)
    clear_wait_callback()