public @Nullable DirectoryEntry get(Name name) {
    int index = bucketIndex(name, table.length);

    DirectoryEntry entry = table[index];
    while (entry != null) {
      if (name.equals(entry.name())) {
        return entry;
      }

      entry = entry.next;
    }
    return null;
  }
@Test
  public void testGet() {
    assertThat(root.get(Name.simple("foo"))).isEqualTo(entry(root, "foo", dir));
    assertThat(dir.get(Name.simple("foo"))).isNull();
    assertThat(root.get(Name.simple("Foo"))).isNull();
  }