Search Options

Results per page
Sort
Preferred Languages
Advance

Results 51 - 60 of 726 for fail (0.16 sec)

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

        List<String> list = Lists.newArrayList("a", "b", "c");
        FluentIterable<String> tail = FluentIterable.from(list).skip(2);
        list.subList(0, 2).clear();
        assertThat(tail).isEmpty();
      }
    
      public void testSkip_illegalArgument() {
        try {
          FluentIterable.from(asList("a", "b", "c")).skip(-1);
          fail("Skipping negative number of elements should throw IllegalArgumentException.");
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Tue Jun 06 17:32:08 GMT 2023
    - 30.6K bytes
    - Viewed (0)
  2. android/guava-tests/test/com/google/common/collect/ImmutableMultimapTest.java

        Builder<String, Integer> builder = new Builder<>();
        try {
          builder.put(Maps.immutableEntry("one", (Integer) null));
          fail();
        } catch (NullPointerException expected) {
        }
        try {
          builder.put(Maps.immutableEntry((String) null, 1));
          fail();
        } catch (NullPointerException expected) {
        }
      }
    
      private static class StringHolder {
        @Nullable String string;
      }
    
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Feb 21 10:16:44 GMT 2024
    - 5.1K bytes
    - Viewed (0)
  3. android/guava-tests/test/com/google/common/net/InternetDomainNameTest.java

          InternetDomainName.from("com").parent();
          fail("'com' should throw ISE on .parent() call");
        } catch (IllegalStateException expected) {
        }
      }
    
      public void testChild() {
        InternetDomainName domain = InternetDomainName.from("foo.com");
    
        assertEquals("www.foo.com", domain.child("www").toString());
    
        try {
          domain.child("www.");
          fail("www..google.com should have been invalid");
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Tue Mar 05 13:16:00 GMT 2024
    - 17.3K bytes
    - Viewed (0)
  4. guava-testlib/src/com/google/common/collect/testing/testers/MapComputeTester.java

                  k0(),
                  (k, v) -> {
                    assertEquals(k0(), k);
                    assertEquals(v0(), v);
                    throw new ExpectedException();
                  });
          fail("Expected ExpectedException");
        } catch (ExpectedException expected) {
        }
        expectUnchanged();
      }
    
      @MapFeature.Require({SUPPORTS_PUT, SUPPORTS_REMOVE})
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Tue Jan 09 20:10:38 GMT 2018
    - 6.8K bytes
    - Viewed (0)
  5. android/guava-tests/test/com/google/common/collect/EnumMultisetTest.java

        assertEquals(2, ms.count(Color.RED));
      }
    
      public void testIllegalCreate() {
        Collection<Color> empty = EnumSet.noneOf(Color.class);
        try {
          EnumMultiset.create(empty);
          fail();
        } catch (IllegalArgumentException expected) {
        }
      }
    
      public void testCreateEmptyWithClass() {
        Multiset<Color> ms = EnumMultiset.create(ImmutableList.<Color>of(), Color.class);
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Mon Feb 26 16:35:21 GMT 2024
    - 5.8K bytes
    - Viewed (0)
  6. android/guava-tests/test/com/google/common/util/concurrent/FutureCallbackTest.java

        FutureCallback<String> callback =
            new FutureCallback<String>() {
              private boolean called = false;
    
              @Override
              public void onSuccess(String result) {
                fail("Was not expecting onSuccess() to be called.");
              }
    
              @Override
              public synchronized void onFailure(Throwable t) {
                assertFalse(called);
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu Apr 06 12:56:11 GMT 2023
    - 6.3K bytes
    - Viewed (0)
  7. guava-testlib/src/com/google/common/collect/testing/SpliteratorTester.java

        if (spliterator.estimateSize() > originalSize) {
          fail(
              format(
                  "estimated size of spliterator after trySplit (%s) is larger than original size (%s)",
                  spliterator.estimateSize(), originalSize));
        }
        if (trySplit != null) {
          if (trySplit.estimateSize() > originalSize) {
            fail(
                format(
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Apr 22 18:19:31 GMT 2024
    - 11.9K bytes
    - Viewed (0)
  8. guava-tests/test/com/google/common/collect/MapsTest.java

        try {
          diff1.entriesInCommon().put(7, "x");
          fail();
        } catch (UnsupportedOperationException expected) {
        }
        try {
          diff1.entriesOnlyOnLeft().put(7, "x");
          fail();
        } catch (UnsupportedOperationException expected) {
        }
        try {
          diff1.entriesOnlyOnRight().put(7, "x");
          fail();
        } catch (UnsupportedOperationException expected) {
        }
      }
    
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Mar 04 16:06:01 GMT 2024
    - 67.2K bytes
    - Viewed (0)
  9. guava-tests/test/com/google/common/collect/MoreCollectorsTest.java

        try {
          stream.collect(MoreCollectors.toOptional());
          fail("Expected NullPointerException");
        } catch (NullPointerException expected) {
        }
      }
    
      public void testToOptionalMultiple() {
        try {
          Stream.of(1, 2).collect(MoreCollectors.toOptional());
          fail("Expected IllegalArgumentException");
        } catch (IllegalArgumentException expected) {
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Thu Mar 07 18:34:03 GMT 2024
    - 3.4K bytes
    - Viewed (0)
  10. guava-tests/test/com/google/common/math/DoubleMathTest.java

            fail("Expected ArithmeticException");
          } catch (ArithmeticException expected) {
          }
        }
      }
    
      @GwtIncompatible // DoubleMath.roundToInt(double, RoundingMode)
      public void testRoundNaNToIntAlwaysFails() {
        for (RoundingMode mode : ALL_ROUNDING_MODES) {
          try {
            DoubleMath.roundToInt(Double.NaN, mode);
            fail("Expected ArithmeticException");
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Wed Feb 07 17:50:39 GMT 2024
    - 28.1K bytes
    - Viewed (0)
Back to top