1 package jalview.fts.threedbeacons;
3 import static org.testng.AssertJUnit.assertEquals;
4 import static org.testng.AssertJUnit.assertTrue;
6 import jalview.fts.service.pdb.PDBFTSPanel;
7 import jalview.fts.service.threedbeacons.TDBeaconsFTSPanel;
8 import jalview.gui.JvOptionPane;
10 import javax.swing.JComboBox;
11 import javax.swing.JInternalFrame;
13 import org.testng.annotations.AfterMethod;
14 import org.testng.annotations.BeforeClass;
15 import org.testng.annotations.BeforeMethod;
16 import org.testng.annotations.Test;
18 import junit.extensions.PA;
20 public class TDBeaconsPanelTest
22 @BeforeClass(alwaysRun = true)
23 public void setUpJvOptionPane()
25 JvOptionPane.setInteractiveMode(false);
26 JvOptionPane.setMockResponse(JvOptionPane.CANCEL_OPTION);
29 @BeforeMethod(alwaysRun = true)
30 public void setUp() throws Exception
34 @AfterMethod(alwaysRun = true)
35 public void tearDown() throws Exception
39 @Test(groups = { "Functional" })
40 public void populateCmbSearchTargetOptionsTest()
42 TDBeaconsFTSPanel searchPanel = new TDBeaconsFTSPanel(null);
43 assertTrue(searchPanel.getCmbSearchTarget().getItemCount() > 0);
44 searchPanel.populateCmbSearchTargetOptions();
48 public void getFTSframeTitleTest()
50 TDBeaconsFTSPanel searchPanel = new TDBeaconsFTSPanel(null);
51 System.out.println(searchPanel.getFTSFrameTitle());
55 public void testgetUNIPROTid()
57 String outcome = TDBeaconsFTSPanel.decodeSearchTerm("P01308");
58 System.out.println(outcome);
62 // public void queryTest() {
63 // int outcome = TDBeaconsFTSPanel.executeParse("P01308");
64 // //System.out.println("query outcome :" + outcome);
65 // int expected_length = 110;
66 // assertEquals(outcome, expected_length);