title: Code for testing my method
body: <p>I'm relatively new to Java programming. I was wondering what could I code to test this method? Could you please post any suggestions? I would like to test my method in a client class. </p>
  
  <pre><code> public void insertThird(Player p)
    {
        PlayerNode pn = new PlayerNode(p);
        PlayerNode current = head;
  
        if (current == null)
            head = pn;
        else
        {
            current = current.getNext();
            if(current!=null)
            {
                pn.setNext(current.getNext());
                current.setNext(pn);
            }
            else
            {
                head.setNext(pn);
            }
        }
        numberOfItems++;
    }
  </code></pre>