Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 20 of 29 for test_hashCode (0.13 sec)

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

        assertSame(mutex, ((SynchronizedSet<?>) entrySet).mutex);
      }
    
      public void testEquals() {
        boolean unused = create().equals(new HashMap<String, Integer>());
      }
    
      public void testHashCode() {
        int unused = create().hashCode();
      }
    
      public void testToString() {
        String unused = create().toString();
      }
    
      public void testSerialization() {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Tue Aug 06 17:23:04 UTC 2024
    - 5.8K bytes
    - Viewed (0)
  2. guava-tests/test/com/google/common/collect/SynchronizedMapTest.java

        assertSame(mutex, ((SynchronizedSet<?>) entrySet).mutex);
      }
    
      public void testEquals() {
        boolean unused = create().equals(new HashMap<String, Integer>());
      }
    
      public void testHashCode() {
        int unused = create().hashCode();
      }
    
      public void testToString() {
        String unused = create().toString();
      }
    
      public void testSerialization() {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Tue Aug 06 17:23:04 UTC 2024
    - 5.8K bytes
    - Viewed (0)
  3. android/guava-tests/test/com/google/common/collect/EmptyImmutableTableTest.java

      @Override
      Iterable<ImmutableTable<Character, Integer, String>> getTestInstances() {
        return ImmutableSet.of(INSTANCE);
      }
    
      public void testHashCode() {
        assertEquals(0, INSTANCE.hashCode());
      }
    
      public void testEqualsObject() {
        Table<Character, Integer, String> nonEmptyTable = HashBasedTable.create();
        nonEmptyTable.put('A', 1, "blah");
    
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Mon Feb 19 20:34:55 UTC 2024
    - 3.2K bytes
    - Viewed (0)
  4. guava-testlib/src/com/google/common/collect/testing/testers/MapHashCodeTester.java

    @Ignore // Affects only Android test runner, which respects JUnit 4 annotations on JUnit 3 tests.
    @SuppressWarnings("JUnit4ClassUsedInJUnit3")
    public class MapHashCodeTester<K, V> extends AbstractMapTester<K, V> {
      public void testHashCode() {
        int expectedHashCode = 0;
        for (Entry<K, V> entry : getSampleEntries()) {
          expectedHashCode += hash(entry);
        }
        assertEquals(
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Jul 24 20:12:35 UTC 2024
    - 3K bytes
    - Viewed (0)
  5. guava-tests/test/com/google/common/collect/AbstractMapEntryTest.java

        assertFalse(entry(NK, 1).equals(control("bar", 1)));
        assertFalse(entry(NK, 1).equals(new Object()));
        assertFalse(entry(NK, 1).equals(null));
      }
    
      public void testHashCode() {
        assertEquals(control("foo", 1).hashCode(), entry("foo", 1).hashCode());
        assertEquals(control("bar", 2).hashCode(), entry("bar", 2).hashCode());
      }
    
      public void testHashCodeNull() {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 3.2K bytes
    - Viewed (0)
  6. guava-tests/test/com/google/common/collect/AbstractTableReadTest.java

            .addEqualityGroup(table, hashCopy, reordered)
            .addEqualityGroup(smaller)
            .addEqualityGroup(swapOuter)
            .addEqualityGroup(swapValues)
            .testEquals();
      }
    
      public void testHashCode() {
        table = create("foo", 1, 'a', "bar", 1, 'b', "foo", 3, 'c');
        int expected =
            Objects.hashCode("foo", 1, 'a')
                + Objects.hashCode("bar", 1, 'b')
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Tue Oct 15 17:36:06 UTC 2024
    - 6.6K bytes
    - Viewed (0)
  7. android/guava-tests/test/com/google/common/collect/AbstractTableReadTest.java

            .addEqualityGroup(table, hashCopy, reordered)
            .addEqualityGroup(smaller)
            .addEqualityGroup(swapOuter)
            .addEqualityGroup(swapValues)
            .testEquals();
      }
    
      public void testHashCode() {
        table = create("foo", 1, 'a', "bar", 1, 'b', "foo", 3, 'c');
        int expected =
            Objects.hashCode("foo", 1, 'a')
                + Objects.hashCode("bar", 1, 'b')
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Tue Oct 15 17:36:06 UTC 2024
    - 6.6K bytes
    - Viewed (0)
  8. android/guava-tests/test/com/google/common/primitives/BytesTest.java

      private static final byte[] ARRAY1 = {(byte) 1};
      private static final byte[] ARRAY234 = {(byte) 2, (byte) 3, (byte) 4};
    
      private static final byte[] VALUES = {Byte.MIN_VALUE, -1, 0, 1, Byte.MAX_VALUE};
    
      public void testHashCode() {
        for (byte value : VALUES) {
          assertThat(Bytes.hashCode(value)).isEqualTo(((Byte) value).hashCode());
        }
      }
    
      public void testContains() {
        assertThat(Bytes.contains(EMPTY, (byte) 1)).isFalse();
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Sat Oct 19 02:56:12 UTC 2024
    - 17.3K bytes
    - Viewed (0)
  9. android/guava-tests/test/com/google/common/primitives/CharsTest.java

      private static final char LEAST = Character.MIN_VALUE;
      private static final char GREATEST = Character.MAX_VALUE;
    
      private static final char[] VALUES = {LEAST, 'a', '\u00e0', '\udcaa', GREATEST};
    
      public void testHashCode() {
        for (char value : VALUES) {
          assertThat(Chars.hashCode(value)).isEqualTo(((Character) value).hashCode());
        }
      }
    
      public void testCheckedCast() {
        for (char value : VALUES) {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Sat Oct 19 02:56:12 UTC 2024
    - 25.6K bytes
    - Viewed (0)
  10. guava-tests/test/com/google/common/primitives/BytesTest.java

      private static final byte[] ARRAY1 = {(byte) 1};
      private static final byte[] ARRAY234 = {(byte) 2, (byte) 3, (byte) 4};
    
      private static final byte[] VALUES = {Byte.MIN_VALUE, -1, 0, 1, Byte.MAX_VALUE};
    
      public void testHashCode() {
        for (byte value : VALUES) {
          assertThat(Bytes.hashCode(value)).isEqualTo(((Byte) value).hashCode());
        }
      }
    
      public void testContains() {
        assertThat(Bytes.contains(EMPTY, (byte) 1)).isFalse();
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Sat Oct 19 02:56:12 UTC 2024
    - 17.3K bytes
    - Viewed (0)
Back to top