Esempio n. 1
0
def test_constructor_open_or_create():
    shared_memory_object(open_or_create, 'MySharedMemory', modes.read_write)
    shared_memory_object(open_or_create, 'MySharedMemory', modes.read_write)
Esempio n. 2
0
def test_remove():
    shared_memory_object(open_or_create, 'MySharedMemory', modes.read_write)
    assert shared_memory_object.remove('MySharedMemory')
Esempio n. 3
0
def test_constructor_create_only():
    shared_memory_object(create_only, 'MySharedMemory', modes.read_write)
    with pytest.raises(RuntimeError):
        shared_memory_object(create_only, 'MySharedMemory', modes.read_write)
Esempio n. 4
0
def test_constructor_different_modes(mode):
    shared_memory_object(open_or_create, 'MySharedMemory', mode)