@@ -0,0 +1,2503 @@
+package nl.tudelft.pl2016gr2.model;%0A%0Aimport org.junit.Test;%0A%0Aimport java.util.ArrayList;%0Aimport java.util.List;%0A%0Aimport static org.junit.Assert.assertEquals;%0Aimport static org.junit.Assert.assertFalse;%0Aimport static org.junit.Assert.assertTrue;%0A%0Apublic class BubbleTest %7B%0A%0A  @Test%0A  public void testConstructor() %7B%0A    Bubble bubble = new Bubble(123, 5);%0A    assertEquals(123, bubble.getId());%0A    assertEquals(5, bubble.getSequenceLength());%0A  %7D%0A%0A  @Test%0A  public void testLevel() %7B%0A    Bubble bubble = new Bubble(123, 5);%0A    bubble.setLevel(12);%0A%0A    assertEquals(12, bubble.getLevel());%0A  %7D%0A%0A  @Test%0A  public void testStartBubble() %7B%0A    Bubble bubble = new Bubble(123, 5);%0A    Bubble startBubble = new Bubble(321, 3);%0A    bubble.setStartBubble(startBubble);%0A%0A    assertEquals(startBubble, bubble.getStartBubble());%0A  %7D%0A%0A  @Test%0A  public void testEndBubble() %7B%0A    Bubble bubble = new Bubble(123, 5);%0A    Bubble endBubble = new Bubble(321, 3);%0A    bubble.setEndBubble(endBubble);%0A%0A    assertEquals(endBubble, bubble.getEndBubble());%0A  %7D%0A%0A  @Test%0A  public void testNestedBubbles() %7B%0A    Bubble bubble = new Bubble(123, 5);%0A    List%3CInteger%3E nestedBubbleIds = new ArrayList%3C%3E();%0A    nestedBubbleIds.add(1);%0A    nestedBubbleIds.add(2);%0A    nestedBubbleIds.add(3);%0A    nestedBubbleIds.add(4);%0A    nestedBubbleIds.add(5);%0A    nestedBubbleIds.add(6);%0A    nestedBubbleIds.forEach(bubble::addNestedBubble);%0A%0A    assertEquals(nestedBubbleIds, bubble.getNestedBubbles());%0A  %7D%0A%0A  @Test%0A  public void testEquals1() %7B%0A    Bubble bubble1 = new Bubble(123, 5);%0A    Bubble bubble2 = new Bubble(123, 5);%0A%0A    assertTrue(bubble1.equals(bubble2));%0A  %7D%0A%0A  @Test%0A  public void testEquals2() %7B%0A    Bubble bubble1 = new Bubble(123, 5);%0A    Bubble bubble2 = new Bubble(122, 7);%0A%0A    assertFalse(bubble1.equals(bubble2));%0A  %7D%0A%0A  @Test%0A  public void testEquals3() %7B%0A    Bubble bubble = new Bubble(123, 5);%0A    Object obj = new Object();%0A%0A    assertFalse(bubble.equals(obj));%0A  %7D%0A%0A  @Test%0A  public void testHashCode() %7B%0A    Bubble bubble1 = new Bubble(123, 5);%0A    Bubble bubble2 = new Bubble(123, 5);%0A%0A    assertEquals(bubble1.hashCode(), bubble2.hashCode());%0A%0A  %7D%0A%0A  /**%0A   * Code that this test tests, is not implemented!!%0A   * Dont forget to amend the test, this test SHOULD fail when%0A   * the this feature is implemented.%0A   */%0A  @Test(expected = UnsupportedOperationException.class)%0A  public void testGetGenomesOverEdge() %7B%0A    Bubble bubble = new Bubble(123, 5);%0A%0A    bubble.getGenomesOverEdge(new Bubble(1, 2));%0A  %7D%0A%0A%7D

test Bubble class