Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 4 of 4 for testRemoveUnsupported (0.13 sec)

  1. guava-tests/test/com/google/common/collect/SimpleAbstractMultisetTest.java

            };
        ImmutableMultiset<String> adds =
            new ImmutableMultiset.Builder<String>().addCopies("x", 10).build();
        multiset.addAll(adds);
        assertEquals(1, addCalls.get());
      }
    
      public void testRemoveUnsupported() {
        Multiset<String> multiset = new NoRemoveMultiset<>();
        multiset.add("a");
        assertThrows(UnsupportedOperationException.class, () -> multiset.remove("a"));
        assertTrue(multiset.contains("a"));
      }
    
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Tue Oct 15 17:36:06 UTC 2024
    - 5.6K bytes
    - Viewed (0)
  2. android/guava-tests/test/com/google/common/collect/SimpleAbstractMultisetTest.java

            };
        ImmutableMultiset<String> adds =
            new ImmutableMultiset.Builder<String>().addCopies("x", 10).build();
        multiset.addAll(adds);
        assertEquals(1, addCalls.get());
      }
    
      public void testRemoveUnsupported() {
        Multiset<String> multiset = new NoRemoveMultiset<>();
        multiset.add("a");
        assertThrows(UnsupportedOperationException.class, () -> multiset.remove("a"));
        assertTrue(multiset.contains("a"));
      }
    
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Tue Oct 15 17:36:06 UTC 2024
    - 5.6K bytes
    - Viewed (0)
  3. android/guava-testlib/src/com/google/common/collect/testing/google/MultisetRemoveTester.java

        assertThrows(IllegalArgumentException.class, () -> getMultiset().remove(e0(), -1));
        expectUnchanged();
      }
    
      @CollectionFeature.Require(absent = SUPPORTS_REMOVE)
      public void testRemoveUnsupported() {
        assertThrows(UnsupportedOperationException.class, () -> getMultiset().remove(e0(), 2));
      }
    
      @CollectionFeature.Require(SUPPORTS_REMOVE)
      public void testRemoveZeroNoOp() {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 6.9K bytes
    - Viewed (0)
  4. android/guava-tests/test/com/google/common/collect/ImmutableRangeSetTest.java

        assertThrows(
            UnsupportedOperationException.class,
            () -> rangeSet.addAll(ImmutableRangeSet.<Integer>of()));
      }
    
      @SuppressWarnings("DoNotCall")
      public void testRemoveUnsupported() {
        RangeSet<Integer> rangeSet =
            ImmutableRangeSet.<Integer>builder()
                .add(Range.closed(5, 8))
                .add(Range.closedOpen(1, 3))
                .build();
    
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Tue Jul 02 18:21:29 UTC 2024
    - 21.5K bytes
    - Viewed (0)
Back to top