Search Options

Results per page
Sort
Preferred Languages
Advance

Results 161 - 170 of 456 for assertThrows (0.12 sec)

  1. guava-tests/test/com/google/common/util/concurrent/SupplementalMonitorTest.java

        Monitor monitor = new Monitor();
        assertThrows(IllegalMonitorStateException.class, () -> monitor.leave());
      }
    
      public void testGetWaitQueueLengthWithWrongMonitorThrowsIMSE() {
        Monitor monitor1 = new Monitor();
        Monitor monitor2 = new Monitor();
        FlagGuard guard = new FlagGuard(monitor2);
        assertThrows(IllegalMonitorStateException.class, () -> monitor1.getWaitQueueLength(guard));
      }
    
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Sep 06 17:04:31 UTC 2023
    - 4.9K bytes
    - Viewed (0)
  2. guava-tests/test/com/google/common/collect/ImmutableSortedMultisetTest.java

        ImmutableSortedMultiset.Builder<String> builder = ImmutableSortedMultiset.naturalOrder();
        assertThrows(NullPointerException.class, () -> builder.add((String) null));
      }
    
      public void testBuilderAddAllHandlesNullsCorrectly() {
        {
          ImmutableSortedMultiset.Builder<String> builder = ImmutableSortedMultiset.naturalOrder();
          assertThrows(NullPointerException.class, () -> builder.addAll((Collection<String>) null));
        }
    
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 22.7K bytes
    - Viewed (0)
  3. android/guava-tests/test/com/google/common/collect/FluentIterableTest.java

            .inOrder();
      }
    
      public void testToMap_nullKey() {
        assertThrows(
            NullPointerException.class, () -> fluent(1, null, 2).toMap(Functions.constant("foo")));
      }
    
      public void testToMap_nullValue() {
        assertThrows(NullPointerException.class, () -> fluent(1, 2, 3).toMap(Functions.constant(null)));
      }
    
      public void testIndex() {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 30.4K bytes
    - Viewed (0)
  4. guava-tests/test/com/google/common/collect/ImmutableListMultimapTest.java

        ImmutableListMultimap.Builder<String, Integer> builder = ImmutableListMultimap.builder();
        assertThrows(NullPointerException.class, () -> builder.put(null, 1));
        assertThrows(NullPointerException.class, () -> builder.putAll(null, Arrays.asList(1, 2, 3)));
        assertThrows(NullPointerException.class, () -> builder.putAll(null, 1, 2, 3));
        assertThrows(
            NullPointerException.class, () -> builder.putAll((Multimap<String, Integer>) toPut));
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 25.4K bytes
    - Viewed (0)
  5. guava-testlib/src/com/google/common/collect/testing/google/AbstractMultisetSetCountTester.java

        assertSetCount(e3(), 1);
        assertThrows(ConcurrentModificationException.class, () -> iterator.next());
      }
    
      @CollectionFeature.Require({SUPPORTS_ADD, FAILS_FAST_ON_CONCURRENT_MODIFICATION})
      public void testSetCountZeroToOneConcurrentWithEntrySetIteration() {
        Iterator<Entry<E>> iterator = getMultiset().entrySet().iterator();
        assertSetCount(e3(), 1);
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Sat Oct 19 00:05:46 UTC 2024
    - 13K bytes
    - Viewed (0)
  6. android/guava-testlib/src/com/google/common/collect/testing/testers/ListGetTester.java

        // This calls get() on each index and checks the result:
        expectContents(createOrderedArray());
      }
    
      public void testGet_negative() {
        assertThrows(IndexOutOfBoundsException.class, () -> getList().get(-1));
      }
    
      public void testGet_tooLarge() {
        assertThrows(IndexOutOfBoundsException.class, () -> getList().get(getNumElements()));
      }
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Thu Oct 17 20:00:30 UTC 2024
    - 1.6K bytes
    - Viewed (0)
  7. android/guava-tests/test/com/google/common/collect/ImmutableMapTest.java

            10);
      }
    
      public void testOfNullKey() {
        assertThrows(NullPointerException.class, () -> ImmutableMap.of(null, 1));
    
        assertThrows(NullPointerException.class, () -> ImmutableMap.of("one", 1, null, 2));
      }
    
      public void testOfNullValue() {
        assertThrows(NullPointerException.class, () -> ImmutableMap.of("one", null));
    
        assertThrows(NullPointerException.class, () -> ImmutableMap.of("one", 1, "two", null));
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 36.6K bytes
    - Viewed (0)
  8. guava-tests/test/com/google/common/collect/ImmutableMultimapTest.java

        Builder<String, Integer> builder = new Builder<>();
        assertThrows(
            NullPointerException.class, () -> builder.put(immutableEntry("one", (Integer) null)));
        assertThrows(NullPointerException.class, () -> builder.put(immutableEntry((String) null, 1)));
      }
    
      public void testBuilderWithExpectedKeysNegative() {
        assertThrows(
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Sat Oct 19 00:05:46 UTC 2024
    - 6.8K bytes
    - Viewed (0)
  9. android/guava-tests/test/com/google/common/reflect/TypesTest.java

      }
    
      public void testNewParameterizedType_invalidTypeParameters() {
        assertThrows(
            IllegalArgumentException.class,
            () -> Types.newParameterizedTypeWithOwner(Map.class, Entry.class, String.class));
      }
    
      public void testNewParameterizedType_primitiveTypeParameters() {
        assertThrows(
            IllegalArgumentException.class,
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Thu Oct 17 13:41:27 UTC 2024
    - 15.2K bytes
    - Viewed (0)
  10. guava-tests/test/com/google/common/reflect/TypesTest.java

      }
    
      public void testNewParameterizedType_invalidTypeParameters() {
        assertThrows(
            IllegalArgumentException.class,
            () -> Types.newParameterizedTypeWithOwner(Map.class, Entry.class, String.class));
      }
    
      public void testNewParameterizedType_primitiveTypeParameters() {
        assertThrows(
            IllegalArgumentException.class,
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Thu Oct 17 13:41:27 UTC 2024
    - 15.2K bytes
    - Viewed (0)
Back to top