@Test
public void testHashCode() {

    final JcrNs base = JcrNs.create(prefix, uri);
    assertEquals("hash codes should be the same for same object", base.hashCode(), base.hashCode());
    final JcrNs same = JcrNs.create(prefix, uri);
    assertEquals("hash codes should be the same for same params", base.hashCode(), same.hashCode());
    final JcrNs diffUri = JcrNs.create(prefix, "http://foo1.com");
    assertNotEquals("hash codes should be diff for diff uri", base.hashCode(), diffUri.hashCode());
    final JcrNs diffPrefix = JcrNs.create("foo1", uri);
    assertNotEquals("hash codes should be diff for diff prefix", base.hashCode(), diffPrefix.hashCode());
    final JcrNs diffBoth = JcrNs.create("foo1", "http://foo1.com");
    assertNotEquals("hash codes should be diff for diff both", base.hashCode(), diffBoth.hashCode());
}