testEquals (), testHashCode () e testToString ()

Eu preparei uma aula curta de Java. Alguém poderia me mostrar como escrever voids: testEquals, testHashCode, testToString para este código em junho? Estou com um pequeno problema;)

public class JW {
    private String name;
    private int quantityVoters;
    private int voted;

    public JW( String nam, int quantityV ) {
        if( nam == null || nam.length() == 0 || quantityV < 10 )
            throw new IllegalArgumentException( "JW: Wrong" );
        name= nam;
        quantityVoters= quantityV;
        voted= 0;
     }

    public void voting( int n ) {
        if( n < 0 || n > quantityVoters - voted )
            throw new IllegalArgumentException( "JW: soething wrong with voting!" );
        else
           voted += n;
    }

    public int novote() {
        return quantityVoters - voted;
    }

    public boolean equals( Object o ) {
        return o != null && o instanceof JW && ((JW)o).name.equals( name );
    }

    public int hashCode() {
        return name.hashCode();
    }

    public String toString() {
        return "JW " + name + ": quantity Voters: " + quantityVoters + ", voted: " + voted;
    }
}

questionAnswers(2)

yourAnswerToTheQuestion