@Override
  public boolean equals( Object object ) {
    if ( !( object instanceof Element ) ) {
      return false;
    }
    if ( this == object ) {
      return true;
    }
    Element other = ( (Element) object );
    return Objects.equals( this.name, other.name )
        && Objects.equals( this.path, other.path )
        && Objects.equals( this.provider, other.provider );
  }
@Test
  public void testEquals() {
    Element element2 = new Element( NAME, TYPE, PATH, LOCAL_PROVIDER );
    assertEquals( element1, element2 );
    element2 = new Element( "diffname", TYPE, "/tmp/diffname", LOCAL_PROVIDER );
    assertNotEquals( element1, element2 );
    element2 = new Element( NAME, TYPE, PATH, "diffProvider" );
    assertNotEquals( element1, element2 );
    element2 = new Element( NAME, EntityType.REPOSITORY_FILE, PATH, LOCAL_PROVIDER );
    // Changing the file type does not effect equals because in a map, if the path and provider are the same then
    // the files would live in the same physical space.
    assertEquals( element1, element2 );

    // future proofing for unexpected null values
    assertNotEquals( new Element( null, null, null, null ), element2 );
  }