- Sort Score
- Result 10 results
- Languages All
Results 111 - 120 of 134 for assertSame (0.18 sec)
-
guava-testlib/src/com/google/common/util/concurrent/testing/AbstractListenableFutureTest.java
if (i == 10) { new Thread(() -> latch.countDown()).start(); } future.addListener(listenerLatch::countDown, exec); } assertSame(Boolean.TRUE, future.get()); // Wait for the listener latch to complete. listenerLatch.await(500, MILLISECONDS); exec.shutdown(); exec.awaitTermination(500, MILLISECONDS); }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Sep 06 18:30:30 UTC 2023 - 6K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/util/concurrent/JSR166TestCase.java
threadUnexpectedException(t); } } /** * Just like assertSame(x, y), but additionally recording (using threadRecordFailure) any * AssertionFailedError thrown, so that the current testcase will fail. */ public void threadAssertSame(Object x, Object y) { try { assertSame(x, y); } catch (AssertionFailedError t) { threadRecordFailure(t); throw t; }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Thu Oct 17 02:42:09 UTC 2024 - 37.9K bytes - Viewed (0) -
guava-tests/test/com/google/common/base/OptionalTest.java
Optional<String> optionalName = Optional.fromNullable("bob"); assertEquals("bob", optionalName.get()); } public void testFromNullable_null() { // not promised by spec, but easier to test assertSame(Optional.absent(), Optional.fromNullable(null)); } public void testIsPresent_no() { assertFalse(Optional.absent().isPresent()); }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Tue Sep 17 18:14:12 UTC 2024 - 10.5K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/util/concurrent/MoreExecutorsTest.java
List<? extends Future<?>> unused = executor.invokeAll(tasks); } public void testListeningDecorator() throws Exception { ListeningExecutorService service = listeningDecorator(newDirectExecutorService()); assertSame(service, listeningDecorator(service)); List<Callable<String>> callables = ImmutableList.of(Callables.returning("x")); List<Future<String>> results; results = service.invokeAll(callables);
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Fri Oct 18 22:10:29 UTC 2024 - 28.1K bytes - Viewed (0) -
guava-tests/test/com/google/common/collect/IteratorsTest.java
Iterator<String> mod = Lists.newArrayList("a", "b", "c").iterator(); UnmodifiableIterator<String> unmod = Iterators.unmodifiableIterator(mod); assertNotSame(mod, unmod); assertSame(unmod, Iterators.unmodifiableIterator(unmod)); assertSame(unmod, Iterators.unmodifiableIterator((Iterator<String>) unmod)); } @SuppressWarnings("deprecation") public void testPeekingIteratorShortCircuit() {
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 16:15:19 UTC 2024 - 54.1K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/collect/IteratorsTest.java
Iterator<String> mod = Lists.newArrayList("a", "b", "c").iterator(); UnmodifiableIterator<String> unmod = Iterators.unmodifiableIterator(mod); assertNotSame(mod, unmod); assertSame(unmod, Iterators.unmodifiableIterator(unmod)); assertSame(unmod, Iterators.unmodifiableIterator((Iterator<String>) unmod)); } @SuppressWarnings("deprecation") public void testPeekingIteratorShortCircuit() {
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 16:15:19 UTC 2024 - 54.1K bytes - Viewed (0) -
guava-tests/test/com/google/common/util/concurrent/JSR166TestCase.java
threadUnexpectedException(t); } } /** * Just like assertSame(x, y), but additionally recording (using threadRecordFailure) any * AssertionFailedError thrown, so that the current testcase will fail. */ public void threadAssertSame(Object x, Object y) { try { assertSame(x, y); } catch (AssertionFailedError t) { threadRecordFailure(t); throw t; }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Thu Oct 17 02:42:09 UTC 2024 - 37.9K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/collect/ImmutableSetTest.java
builder.add("a"); assertEquals(1, builder.size); builder.add("b", "c", "d"); assertEquals(4, builder.size); Object[] table = builder.hashTable; assertNotNull(table); assertSame(table, ((RegularImmutableSet<String>) builder.build()).table); } @GwtIncompatible("Builder impl") public void testPresizedBuilderForceCopy() { for (int expectedSize = 1; expectedSize < 4; expectedSize++) {
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 16:15:19 UTC 2024 - 13.7K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/cache/CacheBuilderSpecTest.java
Object key = new Object(); Object value = new Object(); LoadingCache<Object, Object> cache = builder.build(CacheLoader.from(Suppliers.ofInstance(value))); assertSame(value, cache.getUnchecked(key)); assertEquals(0, cache.size()); assertFalse(cache.asMap().containsKey(key)); } public void testCacheBuilderFrom_string() { CacheBuilder<?, ?> fromString =
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Fri Oct 18 19:07:49 UTC 2024 - 19.1K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/collect/IterablesTest.java
Iterable<String> iterable2 = Iterables.unmodifiableIterable(iterable); assertSame(iterable, iterable2); ImmutableList<String> immutableList = ImmutableList.of("a", "b", "c"); assertSame(immutableList, Iterables.unmodifiableIterable(immutableList)); assertSame(immutableList, Iterables.unmodifiableIterable((List<String>) immutableList)); } public void testFrequency_multiset() {
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 19:12:33 UTC 2024 - 45K bytes - Viewed (0)