@Test
public void testSynchronize() {

    Lock[] locks = new Lock[10];
    for (int i = 0; i < locks.length; i++)
        locks[i] = mock(Lock.class);
    DefaultModelStorage.synchronize(() -> {}, locks);
    for (Lock lock : locks) {
        verify(lock, times(1)).lock();
        verify(lock, times(1)).unlock();
        verifyNoMoreInteractions(lock);
    }
}