Ejemplo n.º 1
0
def test_create_context(display):
    record_range = xrecord.alloc_range()
    record_range.contents.device_events.first = xlib.KEY_PRESS
    record_range.contents.device_events.last = xlib.KEY_RELEASE
    context = None
    try:
        context = xrecord.create_context(
            display, 0, xrecord.ALL_CLIENTS, record_range)
        assert context
    finally:
        if context:
            assert xrecord.free_context(display, context)
Ejemplo n.º 2
0
def test_create_context(display):
    record_range = xrecord.alloc_range()
    record_range.contents.device_events.first = xlib.KEY_PRESS
    record_range.contents.device_events.last = xlib.KEY_RELEASE
    context = None
    try:
        context = xrecord.create_context(display, 0, xrecord.ALL_CLIENTS,
                                         record_range)
        assert context
    finally:
        if context:
            assert xrecord.free_context(display, context)
Ejemplo n.º 3
0
def test_alloc_range():
    r = xrecord.alloc_range()
    assert r
    xlib.free(r)
Ejemplo n.º 4
0
def test_alloc_range():
    r = xrecord.alloc_range()
    assert r
    xlib.free(r)