PHP Класс malkusch\lock\util\DoubleCheckedLockingTest

См. также: DoubleCheckedLocking
Автор: Markus Malkusch ([email protected])
Наследование: extends PHPUnit_Framework_TestCase
Показать файл Открыть проект

Открытые методы

Метод Описание
provideTestCodeNotExecuted ( ) : callable[][] Returns checks for testCodeNotExecuted().
testCheckFailsAcquiresNoLock ( ) Tests that the lock will not be acquired for a failing test.
testCodeExecuted ( ) Tests that the code executed if the checks are true.
testCodeNotExecuted ( callable $check ) Tests that the code is not executed if the first or second check fails.
testLockedCheckAndExecution ( ) Tests that the check and execution are in the same lock.

Защищенные методы

Метод Описание
setUp ( )

Описание методов

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

Returns checks for testCodeNotExecuted().
public provideTestCodeNotExecuted ( ) : callable[][]
Результат callable[][] The test cases.

setUp() защищенный Метод

protected setUp ( )

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

Tests that the lock will not be acquired for a failing test.

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

Tests that the code executed if the checks are true.
public testCodeExecuted ( )

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

Tests that the code is not executed if the first or second check fails.
public testCodeNotExecuted ( callable $check )
$check callable The check.

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

Tests that the check and execution are in the same lock.