Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 20 of 136 for assertThrows (0.2 sec)

  1. android/guava-tests/test/com/google/common/hash/HashCodeTest.java

        assertThrows(IllegalArgumentException.class, () -> HashCode.fromString(""));
        assertThrows(IllegalArgumentException.class, () -> HashCode.fromString("7"));
        HashCode unused = HashCode.fromString("7f");
      }
    
      public void testFromStringFailsWithOddLengthInput() {
        assertThrows(IllegalArgumentException.class, () -> HashCode.fromString("7f8"));
      }
    
      public void testIntWriteBytesTo() {
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 13.1K bytes
    - Viewed (0)
  2. android/guava-tests/test/com/google/common/util/concurrent/AtomicDoubleArrayTest.java

        for (int index : new int[] {-1, SIZE}) {
          assertThrows(IndexOutOfBoundsException.class, () -> aa.get(index));
          assertThrows(IndexOutOfBoundsException.class, () -> aa.set(index, 1.0));
          assertThrows(IndexOutOfBoundsException.class, () -> aa.lazySet(index, 1.0));
          assertThrows(IndexOutOfBoundsException.class, () -> aa.compareAndSet(index, 1.0, 2.0));
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 10K bytes
    - Viewed (0)
  3. guava-tests/test/com/google/common/graph/ValueGraphTest.java

        graph.putEdgeValue(1, 2, "A");
        IllegalArgumentException e =
            assertThrows(
                IllegalArgumentException.class, () -> graph.edgeValue(EndpointPair.unordered(1, 2)));
        assertThat(e).hasMessageThat().contains(ENDPOINTS_MISMATCH);
        e =
            assertThrows(
                IllegalArgumentException.class, () -> graph.edgeValue(EndpointPair.unordered(2, 1)));
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Tue Feb 06 18:35:19 GMT 2024
    - 20K bytes
    - Viewed (0)
  4. android/guava-tests/test/com/google/common/cache/CacheBuilderTest.java

        assertThrows(IllegalArgumentException.class, () -> builder.maximumWeight(-1));
      }
    
      @GwtIncompatible // maximumWeight
      public void testMaximumWeight_setTwice() {
        CacheBuilder<Object, Object> builder = CacheBuilder.newBuilder().maximumWeight(16);
        assertThrows(IllegalStateException.class, () -> builder.maximumWeight(16));
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Tue Oct 03 20:10:02 GMT 2023
    - 23.2K bytes
    - Viewed (0)
  5. maven-core/src/test/java/org/apache/maven/project/DefaultMavenProjectBuilderTest.java

    import static org.junit.jupiter.api.Assertions.assertFalse;
    import static org.junit.jupiter.api.Assertions.assertNotNull;
    import static org.junit.jupiter.api.Assertions.assertNull;
    import static org.junit.jupiter.api.Assertions.assertThrows;
    import static org.junit.jupiter.api.Assertions.assertTrue;
    import static org.junit.jupiter.api.Assertions.fail;
    
    class DefaultMavenProjectBuilderTest extends AbstractMavenProjectTestCase {
        @TempDir
    Java
    - Registered: Sun Apr 28 03:35:10 GMT 2024
    - Last Modified: Mon Jun 19 15:04:04 GMT 2023
    - 16.5K bytes
    - Viewed (0)
  6. android/guava-tests/test/com/google/common/util/concurrent/AbstractScheduledServiceTest.java

    import static java.util.concurrent.TimeUnit.MILLISECONDS;
    import static java.util.concurrent.TimeUnit.NANOSECONDS;
    import static java.util.concurrent.TimeUnit.SECONDS;
    import static org.junit.Assert.assertThrows;
    
    import com.google.common.util.concurrent.AbstractScheduledService.Cancellable;
    import com.google.common.util.concurrent.AbstractScheduledService.Scheduler;
    import com.google.common.util.concurrent.Service.State;
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 22.5K bytes
    - Viewed (0)
  7. guava-tests/test/com/google/common/util/concurrent/AbstractServiceTest.java

        StopFailingService service = new StopFailingService();
        assertThrows(IllegalStateException.class, () -> service.failureCause());
        service.startAsync().awaitRunning();
        assertThrows(IllegalStateException.class, () -> service.failureCause());
        IllegalStateException e =
            assertThrows(IllegalStateException.class, () -> service.stopAsync().awaitTerminated());
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 29.3K bytes
    - Viewed (0)
  8. guava-tests/test/com/google/common/math/StatsAccumulatorTest.java

      }
    
      public void testSampleVariance() {
        assertThrows(IllegalStateException.class, () -> emptyAccumulator.sampleVariance());
        assertThrows(
            IllegalStateException.class, () -> emptyAccumulatorByAddAllEmptyIterable.sampleVariance());
        assertThrows(
            IllegalStateException.class, () -> emptyAccumulatorByAddAllEmptyStats.sampleVariance());
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 36.5K bytes
    - Viewed (0)
  9. android/guava-tests/test/com/google/common/util/concurrent/FuturesGetCheckedTest.java

        SettableFuture<String> future = SettableFuture.create();
        future.cancel(true);
        assertThrows(
            CancellationException.class, () -> getChecked(future, TwoArgConstructorException.class));
      }
    
      public void testGetCheckedUntimed_ExecutionExceptionChecked() {
        TwoArgConstructorException expected =
            assertThrows(
                TwoArgConstructorException.class,
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 16.4K bytes
    - Viewed (0)
  10. guava-tests/test/com/google/common/hash/BloomFilterTest.java

          }
        }
      }
    
      public void testPreconditions() {
        assertThrows(
            IllegalArgumentException.class,
            () -> BloomFilter.create(Funnels.unencodedCharsFunnel(), -1));
        assertThrows(
            IllegalArgumentException.class,
            () -> BloomFilter.create(Funnels.unencodedCharsFunnel(), -1, 0.03));
        assertThrows(
            IllegalArgumentException.class,
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Thu Nov 09 22:49:56 GMT 2023
    - 21.3K bytes
    - Viewed (0)
Back to top