class Election {

    @Override
    public boolean equals(Object obj) {
        if(obj instanceof Election) {
            Election that = (Election) obj;
            return this.getPlace().equals(that.getPlace()) &&
                    this.getKind().equals(that.getKind()) &&
                    this.getAsset().getName().equals(that.getAsset().getName());
        } else {
            return false;
        }
    }

}

class ElectionTest {

    private Sha256Hash mockHash;

    @Test
    public void equalsNonEqualKind() throws Exception {

        Election e1 = new Election("Delft", "Municipal election", new Asset("G_Delft", mockHash));
        Election e2 = new Election("Delft", "Provincial election", new Asset("G_Delft", mockHash));
        assertFalse(e1.equals(e2));
    }

}