Added branch name tests
authorkjvdheide <kjvanderheide@dundee.ac.uk>
Wed, 25 Oct 2017 15:08:16 +0000 (16:08 +0100)
committerkjvdheide <kjvanderheide@dundee.ac.uk>
Wed, 25 Oct 2017 15:08:16 +0000 (16:08 +0100)
test/jalview/ext/archaeopteryx/AptxJalviewTreeTest.java
test/jalview/ext/archaeopteryx/AptxPhylogenyTreeTest.java
test/jalview/ext/archaeopteryx/TreeViewTest.java

index 4fdc473..f7ec7d6 100644 (file)
@@ -52,6 +52,7 @@ public class AptxJalviewTreeTest extends TreeViewTest
             similarityParams);
   }
 
+  @Override
   @BeforeClass(dependsOnMethods = { "setUpTree" })
   public void createTreeView()
   {
@@ -96,4 +97,19 @@ public class AptxJalviewTreeTest extends TreeViewTest
     // TODO Auto-generated method stub
 
   }
+
+
+  @Override
+  public void testInvalidBranchName()
+  {
+    // TODO Auto-generated method stub
+
+  }
+
+  @Override
+  public void testExistingBranchName()
+  {
+    // TODO Auto-generated method stub
+
+  }
 }
index 5e00496..bc908e2 100644 (file)
@@ -58,6 +58,7 @@ public class AptxPhylogenyTreeTest extends TreeViewTest
 
   }
 
+  @Override
   @BeforeClass(dependsOnMethods = { "setUpJalview", "setUpTree" })
   public void createTreeView()
   {
@@ -89,6 +90,24 @@ public class AptxPhylogenyTreeTest extends TreeViewTest
   }
 
   @Override
+  @Test(
+    groups = "Functional",
+    expectedExceptions = IllegalArgumentException.class)
+  public void testInvalidBranchName()
+  {
+    tree.getNode("I shouldn't exist");
+
+  }
+
+  @Override
+  @Test(groups = "Functional")
+  public void testExistingBranchName()
+  {
+    tree.getNode("leaf 2");
+
+  }
+
+  @Override
   @Test(groups = "Functional")
   public void testTreeLoaded()
   {
@@ -133,4 +152,5 @@ public class AptxPhylogenyTreeTest extends TreeViewTest
 
 
 
+
 }
index 972263d..013663e 100644 (file)
@@ -27,6 +27,9 @@ public abstract class TreeViewTest
     Jalview.main(args);
   }
 
+  @BeforeClass(dependsOnMethods = { "setUpJalview", "setUpTree" })
+  public abstract void createTreeView();
+
   @Test(groups = "Functional")
   public void testTreeViewExists()
   {
@@ -45,10 +48,18 @@ public abstract class TreeViewTest
     assertTrue(treeView.isShowing());
   }
 
+  @Test(
+    groups = "Functional",
+    expectedExceptions = IllegalArgumentException.class)
+  public abstract void testInvalidBranchName();
+
   @Test(groups = "Functional")
   public abstract void testTreeLoaded();
 
   @Test(groups = "Functional")
+  public abstract void testExistingBranchName();
+
+  @Test(groups = "Functional")
   public abstract void testChildNodesCount();
 
   @Test(groups = "Functional")