Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 45 for resetContainer (0.1 sec)

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

        for (K key : keys) {
          resetCollection();
          assertTrue(multimap().asMap().remove(key) instanceof List);
        }
      }
    
      @CollectionSize.Require(SEVERAL)
      public void testEquals() {
        resetContainer(mapEntry(k0(), v0()), mapEntry(k1(), v0()), mapEntry(k0(), v3()));
        Map<K, Collection<V>> expected = Maps.newHashMap();
        expected.put(k0(), Lists.newArrayList(v0(), v3()));
        expected.put(k1(), Lists.newArrayList(v0()));
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 3.9K bytes
    - Viewed (0)
  2. android/guava-testlib/src/com/google/common/collect/testing/AbstractCollectionTester.java

      @Override
      @CanIgnoreReturnValue
      protected Collection<E> resetContainer(Collection<E> newContents) {
        collection = super.resetContainer(newContents);
        return collection;
      }
    
      /** @see AbstractContainerTester#resetContainer() */
      protected void resetCollection() {
        resetContainer();
      }
    
      /** @return an array of the proper size with {@code null} inserted into the middle element. */
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Jul 24 20:12:35 UTC 2024
    - 2.7K bytes
    - Viewed (0)
  3. android/guava-testlib/src/com/google/common/collect/testing/google/AbstractMultimapTester.java

      @Override
      @CanIgnoreReturnValue
      protected M resetContainer(M newContents) {
        multimap = super.resetContainer(newContents);
        return multimap;
      }
    
      @CanIgnoreReturnValue
      protected Multimap<K, V> resetContainer(Entry<K, V>... newContents) {
        multimap = super.resetContainer(getSubjectGenerator().create((Object[]) newContents));
        return multimap;
      }
    
      /**
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 6K bytes
    - Viewed (0)
  4. android/guava-testlib/src/com/google/common/collect/testing/google/MultimapKeysTester.java

    @SuppressWarnings("JUnit4ClassUsedInJUnit3")
    public class MultimapKeysTester<K, V> extends AbstractMultimapTester<K, V, Multimap<K, V>> {
      @CollectionSize.Require(SEVERAL)
      public void testKeys() {
        resetContainer(mapEntry(k0(), v0()), mapEntry(k0(), v1()), mapEntry(k1(), v0()));
        Multiset<K> keys = multimap().keys();
        assertEquals(2, keys.count(k0()));
        assertEquals(1, keys.count(k1()));
        assertEquals(3, keys.size());
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 4.2K bytes
    - Viewed (0)
  5. guava-testlib/src/com/google/common/collect/testing/google/SetMultimapAsMapTester.java

        for (K key : keys) {
          resetCollection();
          assertTrue(multimap().asMap().remove(key) instanceof Set);
        }
      }
    
      @CollectionSize.Require(SEVERAL)
      public void testEquals() {
        resetContainer(mapEntry(k0(), v0()), mapEntry(k1(), v0()), mapEntry(k0(), v3()));
        Map<K, Collection<V>> expected = Maps.newHashMap();
        expected.put(k0(), newHashSet(v0(), v3()));
        expected.put(k1(), newHashSet(v0()));
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 3.9K bytes
    - Viewed (0)
  6. guava-testlib/src/com/google/common/collect/testing/google/MultimapKeysTester.java

    @SuppressWarnings("JUnit4ClassUsedInJUnit3")
    public class MultimapKeysTester<K, V> extends AbstractMultimapTester<K, V, Multimap<K, V>> {
      @CollectionSize.Require(SEVERAL)
      public void testKeys() {
        resetContainer(mapEntry(k0(), v0()), mapEntry(k0(), v1()), mapEntry(k1(), v0()));
        Multiset<K> keys = multimap().keys();
        assertEquals(2, keys.count(k0()));
        assertEquals(1, keys.count(k1()));
        assertEquals(3, keys.size());
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 4.2K bytes
    - Viewed (0)
  7. android/guava-testlib/src/com/google/common/collect/testing/AbstractContainerTester.java

      /**
       * Replaces the existing container under test with a new container created by the subject
       * generator.
       *
       * @see #resetContainer(Object) resetContainer(C)
       * @return the new container instance.
       */
      @CanIgnoreReturnValue
      protected C resetContainer() {
        return resetContainer(getSubjectGenerator().createTestSubject());
      }
    
      /**
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 8.8K bytes
    - Viewed (0)
  8. android/guava-testlib/src/com/google/common/collect/testing/google/ListMultimapRemoveTester.java

    public class ListMultimapRemoveTester<K, V> extends AbstractListMultimapTester<K, V> {
      @MapFeature.Require(SUPPORTS_REMOVE)
      @CollectionSize.Require(SEVERAL)
      public void testMultimapRemoveDeletesFirstOccurrence() {
        resetContainer(mapEntry(k0(), v0()), mapEntry(k0(), v1()), mapEntry(k0(), v0()));
    
        List<V> list = multimap().get(k0());
        multimap().remove(k0(), v0());
        assertContentsInOrder(list, v1(), v0());
      }
    
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Sat Oct 19 00:05:46 UTC 2024
    - 3.6K bytes
    - Viewed (0)
  9. android/guava-testlib/src/com/google/common/collect/testing/google/MultimapAsMapTester.java

        assertGet(k0());
        assertEquals(getNumElements() - 1, multimap().size());
      }
    
      @CollectionSize.Require(SEVERAL)
      @MapFeature.Require(SUPPORTS_PUT)
      public void testAsMapEntrySetReflectsPutSameKey() {
        resetContainer(mapEntry(k0(), v0()), mapEntry(k0(), v3()));
    
        Set<Entry<K, Collection<V>>> asMapEntrySet = multimap().asMap().entrySet();
        Collection<V> valueCollection = getOnlyElement(asMapEntrySet).getValue();
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 5.7K bytes
    - Viewed (0)
  10. android/guava-testlib/src/com/google/common/collect/testing/google/ListMultimapReplaceValuesTester.java

      @MapFeature.Require({SUPPORTS_PUT, SUPPORTS_REMOVE})
      public void testReplaceValuesPreservesOrder() {
        List<V> values = asList(v3(), v1(), v4());
    
        for (K k : sampleKeys()) {
          resetContainer();
          multimap().replaceValues(k, values);
          assertGet(k, values);
        }
      }
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Sat Oct 19 00:05:46 UTC 2024
    - 1.7K bytes
    - Viewed (0)
Back to top