Search Options

Results per page
Sort
Preferred Languages
Advance

Results 751 - 760 of 825 for assertequal (0.1 sec)

  1. guava-testlib/src/com/google/common/collect/testing/google/MultisetSetCountUnconditionallyTester.java

    @SuppressWarnings("JUnit4ClassUsedInJUnit3")
    public class MultisetSetCountUnconditionallyTester<E> extends AbstractMultisetSetCountTester<E> {
      @Override
      void setCountCheckReturnValue(E element, int count) {
        assertEquals(
            "multiset.setCount() should return the old count",
            getMultiset().count(element),
            setCount(element, count));
      }
    
      @Override
      void setCountNoCheckReturnValue(E element, int count) {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Jul 24 20:12:35 UTC 2024
    - 1.7K bytes
    - Viewed (0)
  2. guava-testlib/src/com/google/common/collect/testing/testers/MapSizeTester.java

    @SuppressWarnings("JUnit4ClassUsedInJUnit3")
    public class MapSizeTester<K, V> extends AbstractMapTester<K, V> {
      public void testSize() {
        assertEquals("size():", getNumElements(), getMap().size());
      }
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Jul 24 20:12:35 UTC 2024
    - 1.3K bytes
    - Viewed (0)
  3. guava-testlib/src/com/google/common/collect/testing/google/BiMapEntrySetTester.java

      @MapFeature.Require(SUPPORTS_PUT)
      @CollectionSize.Require(absent = ZERO)
      public void testSetValue_valueAbsent() {
        for (Entry<K, V> entry : getMap().entrySet()) {
          if (entry.getKey().equals(k0())) {
            assertEquals("entry.setValue() should return the old value", v0(), entry.setValue(v3()));
          }
        }
        expectReplacement(entry(k0(), v3()));
      }
    
      @MapFeature.Require(SUPPORTS_PUT)
      @CollectionSize.Require(SEVERAL)
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Thu Oct 17 19:10:20 UTC 2024
    - 2.9K bytes
    - Viewed (0)
  4. guava-testlib/src/com/google/common/collect/testing/google/MultimapContainsEntryTester.java

        assertFalse(multimap().containsEntry(k3(), v3()));
      }
    
      public void testContainsEntryAgreesWithGet() {
        for (K k : sampleKeys()) {
          for (V v : sampleValues()) {
            assertEquals(multimap().get(k).contains(v), multimap().containsEntry(k, v));
          }
        }
      }
    
      @CollectionSize.Require(absent = ZERO)
      @MapFeature.Require({ALLOWS_NULL_KEYS, ALLOWS_NULL_VALUES})
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Thu Oct 17 19:10:20 UTC 2024
    - 3.1K bytes
    - Viewed (0)
  5. guava-testlib/src/com/google/common/testing/EqualsTester.java

     * limitations under the License.
     */
    
    package com.google.common.testing;
    
    import static com.google.common.base.Preconditions.checkNotNull;
    import static junit.framework.Assert.assertEquals;
    import static junit.framework.Assert.assertTrue;
    
    import com.google.common.annotations.GwtCompatible;
    import com.google.common.base.Equivalence;
    import com.google.common.collect.Iterables;
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Tue Oct 31 19:11:50 UTC 2023
    - 6K bytes
    - Viewed (0)
  6. android/guava-testlib/src/com/google/common/collect/testing/Helpers.java

    import static java.lang.Math.max;
    import static java.util.Arrays.asList;
    import static java.util.Collections.singletonMap;
    import static java.util.Collections.sort;
    import static junit.framework.Assert.assertEquals;
    import static junit.framework.Assert.assertFalse;
    import static junit.framework.Assert.assertTrue;
    import static junit.framework.Assert.fail;
    
    import com.google.common.annotations.GwtCompatible;
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 17.5K bytes
    - Viewed (0)
  7. guava-testlib/src/com/google/common/collect/testing/testers/MapClearTester.java

      @MapFeature.Require(SUPPORTS_REMOVE)
      public void testClear() {
        getMap().clear();
        assertTrue("After clear(), a map should be empty.", getMap().isEmpty());
        assertEquals(0, getMap().size());
        assertFalse(getMap().entrySet().iterator().hasNext());
      }
    
      @MapFeature.Require({FAILS_FAST_ON_CONCURRENT_MODIFICATION, SUPPORTS_REMOVE})
      @CollectionSize.Require(SEVERAL)
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Thu Oct 17 20:00:30 UTC 2024
    - 3.8K bytes
    - Viewed (0)
  8. guava-testlib/src/com/google/common/collect/testing/testers/MapForEachTester.java

      @CollectionFeature.Require(KNOWN_ORDER)
      public void testForEachKnownOrder() {
        List<Entry<K, V>> entries = new ArrayList<>();
        getMap().forEach((k, v) -> entries.add(entry(k, v)));
        assertEquals(getOrderedElements(), entries);
      }
    
      @CollectionFeature.Require(absent = KNOWN_ORDER)
      public void testForEachUnknownOrder() {
        List<Entry<K, V>> entries = new ArrayList<>();
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 3.2K bytes
    - Viewed (0)
  9. guava-tests/test/com/google/common/io/FileBackedOutputStreamAndroidIncompatibleTest.java

        byte[] data = newPreFilledByteArray(100);
        FileBackedOutputStream out = new FileBackedOutputStream(0, true);
    
        write(out, data, 0, 100, true);
        final File file = out.getFile();
        assertEquals(100, file.length());
        assertTrue(file.exists());
        out.close();
    
        // Make sure that finalize deletes the file
        out = null;
    
        // times out and throws RuntimeException on failure
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Thu Jun 08 21:20:23 UTC 2023
    - 1.7K bytes
    - Viewed (0)
  10. guava-tests/test/com/google/common/collect/UnmodifiableIteratorTest.java

                if (!hasNext()) {
                  throw new NoSuchElementException();
                }
                return array[i++];
              }
            };
    
        assertTrue(iterator.hasNext());
        assertEquals("a", iterator.next());
        assertThrows(UnsupportedOperationException.class, () -> iterator.remove());
      }
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Tue Oct 15 17:36:06 UTC 2024
    - 1.7K bytes
    - Viewed (0)
Back to top