- Sort Score
- Result 10 results
- Languages All
Results 1 - 7 of 7 for FakeTicker (0.41 sec)
-
android/guava-testlib/src/com/google/common/testing/FakeTicker.java
* @since 10.0 */ @NullMarked @GwtCompatible public class FakeTicker extends Ticker { private final AtomicLong nanos = new AtomicLong(); private volatile long autoIncrementStepNanos; /** Advances the ticker value by {@code time} in {@code timeUnit}. */ @SuppressWarnings("GoodTime") // should accept a java.time.Duration @CanIgnoreReturnValue public FakeTicker advance(long time, TimeUnit timeUnit) {
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Mon Apr 14 15:16:19 UTC 2025 - 4.1K bytes - Viewed (0) -
guava-testlib/src/com/google/common/testing/FakeTicker.java
* @since 10.0 */ @NullMarked @GwtCompatible public class FakeTicker extends Ticker { private final AtomicLong nanos = new AtomicLong(); private volatile long autoIncrementStepNanos; /** Advances the ticker value by {@code time} in {@code timeUnit}. */ @SuppressWarnings("GoodTime") // should accept a java.time.Duration @CanIgnoreReturnValue public FakeTicker advance(long time, TimeUnit timeUnit) {
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Mon Apr 14 15:16:19 UTC 2025 - 3.4K bytes - Viewed (0) -
android/guava-testlib/test/com/google/common/testing/FakeTickerTest.java
assertEquals(2000010L, ticker.read()); } public void testAutoIncrementStep_returnsSameInstance() { FakeTicker ticker = new FakeTicker(); assertSame(ticker, ticker.setAutoIncrementStep(10, NANOSECONDS)); } public void testAutoIncrementStep_nanos() { FakeTicker ticker = new FakeTicker().setAutoIncrementStep(10, NANOSECONDS); assertEquals(0, ticker.read()); assertEquals(10, ticker.read());
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Thu Aug 07 16:05:33 UTC 2025 - 6.5K bytes - Viewed (0) -
guava-testlib/test/com/google/common/testing/FakeTickerTest.java
assertEquals(2000010L, ticker.read()); } public void testAutoIncrementStep_returnsSameInstance() { FakeTicker ticker = new FakeTicker(); assertSame(ticker, ticker.setAutoIncrementStep(10, NANOSECONDS)); } public void testAutoIncrementStep_nanos() { FakeTicker ticker = new FakeTicker().setAutoIncrementStep(10, NANOSECONDS); assertEquals(0, ticker.read()); assertEquals(10, ticker.read());
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Thu Aug 07 16:05:33 UTC 2025 - 6.3K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/cache/CacheRefreshTest.java
import com.google.common.testing.FakeTicker; import junit.framework.TestCase; import org.jspecify.annotations.NullUnmarked; /** * Tests relating to automatic cache refreshing. * * @author Charles Fry */ @NullUnmarked public class CacheRefreshTest extends TestCase { public void testAutoRefresh() { FakeTicker ticker = new FakeTicker(); IncrementingLoader loader = incrementingLoader();
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Thu Dec 19 18:03:30 UTC 2024 - 4K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/base/StopwatchTest.java
import com.google.common.testing.FakeTicker; import java.time.Duration; import junit.framework.TestCase; import org.jspecify.annotations.NullUnmarked; /** * Unit test for {@link Stopwatch}. * * @author Kevin Bourrillion */ @GwtCompatible @NullUnmarked public class StopwatchTest extends TestCase { private final FakeTicker ticker = new FakeTicker();
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Thu Aug 07 16:05:33 UTC 2025 - 6.1K bytes - Viewed (0) -
guava-tests/test/com/google/common/cache/CacheRefreshTest.java
import com.google.common.testing.FakeTicker; import junit.framework.TestCase; import org.jspecify.annotations.NullUnmarked; /** * Tests relating to automatic cache refreshing. * * @author Charles Fry */ @NullUnmarked public class CacheRefreshTest extends TestCase { public void testAutoRefresh() { FakeTicker ticker = new FakeTicker(); IncrementingLoader loader = incrementingLoader();
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Thu Dec 19 18:03:30 UTC 2024 - 4K bytes - Viewed (0)