title: Java: No exception message error
body: <p>Using BlueJ, and still new to java. I'm having issues when I run my test it comes back stating there is "no exception message".  I don't know where to look through my code to fix this problem.  So here is what I have so far:</p>
  
  <p>Main class</p>
  
  <pre><code>public class LList&lt;X&gt;
  {
      private Node&lt;X&gt; head;
      private int length = 0;
  
  public int size()
  {
      return length;
  }
  
  public void add(X item)
  {
      Node a = new Node();
      a.setValue(item);
      a.setLink(head);
      head = a;
      length ++;
  }
  
  public X get(int index)
      {
          X holder = null;
          Node&lt;X&gt; h = head;
          if(index &gt; length)
          {
              throw new IndexOutOfBoundsException();
          }
          else
          {
              for(int i = 0; i &lt; index + 1; i++)
              {
                  h = h.getLink();
                  holder = h.getValue();
              }
              return holder;
          }
  
      }
  }
  </code></pre>
  
  <p>Next Class</p>
  
  <pre><code> public class Node&lt;X&gt;
  {
      private X value;
      private Node link;
  
      public X getValue()
      {
          return value;
      }
  
      public void setValue(X v)
      {
          value = v;
      }
  
      public void setLink(Node l)
      {
          link = l;
      }
  
      public Node getLink()
      {
          return link;
      }    
  }
  </code></pre>
  
  <p>Test Class</p>
  
  <pre><code>import static org.junit.Assert.*;
  import org.junit.After;
  import org.junit.Before;
  import org.junit.Test;
  public class LListTest
  
  
  @Test
      public void testGet()
      {
          LList x = new &lt;String&gt;LList();
          x.add("hi");
          assertEquals("hi", x.get(0));
          x.add("1hi");
          assertEquals("hi", x.get(1));
          assertEquals("1hi", x.get(0));
          x.add("2hi");
          assertEquals("hi", x.get(2));
          assertEquals("1hi", x.get(1));
          assertEquals("2hi", x.get(0));
          x.add("3hi");
          assertEquals("hi", x.get(3));
          assertEquals("1hi", x.get(2));
          assertEquals("2hi", x.get(1));
          assertEquals("3hi", x.get(0));
          x.add("4hi");
          assertEquals("hi", x.get(4));
          assertEquals("1hi", x.get(3));
          assertEquals("2hi", x.get(2));
          assertEquals("3hi", x.get(1));
          assertEquals("4hi", x.get(0));
      }
  </code></pre>
  
  <p>If there are any ideas I'd greatly appreciate it, whether thats explaining where in my code the issue lies or an explanation on why im getting the error would be awesome.</p>