malkusch\lock\mutex\MutexTest::testRelease PHP Метод

testRelease() публичный Метод

Tests that synchronized() released the lock.
public testRelease ( callable $mutexFactory )
$mutexFactory callable The Mutex factory.
    public function testRelease(callable $mutexFactory)
    {
        $mutex = call_user_func($mutexFactory);
        $mutex->synchronized(function () {
        });
        $mutex->synchronized(function () {
        });
    }