diff --git a/src/Symfony/Component/Lock/StoreInterface.php b/src/Symfony/Component/Lock/StoreInterface.php index 985c4476d7..a45c93aec9 100644 --- a/src/Symfony/Component/Lock/StoreInterface.php +++ b/src/Symfony/Component/Lock/StoreInterface.php @@ -43,7 +43,7 @@ interface StoreInterface * * If the store does not support this feature it should throw a NotSupportedException. * - * @param float $ttl amount of second to keep the lock in the store + * @param float $ttl amount of seconds to keep the lock in the store * * @throws LockConflictedException * @throws NotSupportedException diff --git a/src/Symfony/Component/Lock/Tests/Store/BlockingStoreTestTrait.php b/src/Symfony/Component/Lock/Tests/Store/BlockingStoreTestTrait.php index c04c01d64f..67ac4e1036 100644 --- a/src/Symfony/Component/Lock/Tests/Store/BlockingStoreTestTrait.php +++ b/src/Symfony/Component/Lock/Tests/Store/BlockingStoreTestTrait.php @@ -36,7 +36,7 @@ trait BlockingStoreTestTrait */ public function testBlockingLocks() { - // Amount a microsecond used to order async actions + // Amount of microseconds we should wait without slowing things down too much $clockDelay = 50000; if (\PHP_VERSION_ID < 50600 || \defined('HHVM_VERSION_ID')) { diff --git a/src/Symfony/Component/Lock/Tests/Store/ExpiringStoreTestTrait.php b/src/Symfony/Component/Lock/Tests/Store/ExpiringStoreTestTrait.php index 10b1327387..9a0c5bd260 100644 --- a/src/Symfony/Component/Lock/Tests/Store/ExpiringStoreTestTrait.php +++ b/src/Symfony/Component/Lock/Tests/Store/ExpiringStoreTestTrait.php @@ -20,7 +20,9 @@ use Symfony\Component\Lock\StoreInterface; trait ExpiringStoreTestTrait { /** - * Amount a microsecond used to order async actions. + * Amount of microseconds used as a delay to test expiration. Should be + * small enough not to slow the test suite too much, and high enough not to + * fail because of race conditions. * * @return int */ @@ -34,7 +36,7 @@ trait ExpiringStoreTestTrait /** * Tests the store automatically delete the key when it expire. * - * This test is time sensible: the $clockDelay could be adjust. + * This test is time-sensitive: the $clockDelay could be adjusted. */ public function testExpiration() { @@ -71,14 +73,13 @@ trait ExpiringStoreTestTrait /** * Tests the refresh can push the limits to the expiration. * - * This test is time sensible: the $clockDelay could be adjust. + * This test is time-sensitive: the $clockDelay could be adjusted. */ public function testRefreshLock() { - // Amount a microsecond used to order async actions + // Amount of microseconds we should wait without slowing things down too much $clockDelay = $this->getClockDelay(); - // Amount a microsecond used to order async actions $key = new Key(uniqid(__METHOD__, true)); /** @var StoreInterface $store */