"foo=',',min='foo',max='1,2,3',fa=','", ",").length == 4);
assertTrue("separatorListToArray is faulty.",
RestServiceDescription.separatorListToArray(
- "minsize='2', sep=','", ",").length != 2); // probably should come as 2
+ "minsize='2', sep=','", ",").length != 2); // probably
+ // should come as
+ // 2
}
@Test
testRsdExchange("Test using default Shmmr service",
RestClient.makeShmmrRestClient().service));
}
+
@Test
public void testShmmrServiceDataprep() throws Exception
{
RestClient _rc = RestClient.makeShmmrRestClient();
assertNotNull(_rc);
- AlignFrame alf = new jalview.io.FileLoader(false).LoadFileWaitTillLoaded("examples/testdata/smad.fa", jalview.io.FormatAdapter.FILE);
- assertNotNull("Couldn't find test data.",alf);
+ AlignFrame alf = new jalview.io.FileLoader(false)
+ .LoadFileWaitTillLoaded("examples/testdata/smad.fa",
+ jalview.io.FormatAdapter.FILE);
+ assertNotNull("Couldn't find test data.", alf);
alf.loadJalviewDataFile("examples/testdata/smad_groups.jva",
jalview.io.FormatAdapter.FILE, null, null);
- assertTrue("Couldn't load the test data's annotation file (should be 5 groups but found "+alf.getViewport().getAlignment().getGroups().size()+").", alf.getViewport().getAlignment().getGroups().size()==5);
-
+ assertTrue(
+ "Couldn't load the test data's annotation file (should be 5 groups but found "
+ + alf.getViewport().getAlignment().getGroups().size()
+ + ").", alf.getViewport().getAlignment().getGroups()
+ .size() == 5);
+
RestClient rc = new RestClient(_rc.service, alf, true);
-
-
-
- assertNotNull("Couldn't creat RestClient job.",rc);
+
+ assertNotNull("Couldn't creat RestClient job.", rc);
jalview.bin.Cache.initLogger();
- RestJob rjb = new RestJob(0, new RestJobThread(rc),rc.av.getAlignment(),null);
- rjb.setAlignmentForInputs(rc.service.getInputParams().values(), rc.av.getAlignment());
- for (Map.Entry<String,InputType> e:rc.service.getInputParams().entrySet()) {
- System.out.println("For Input '"+e.getKey()+":\n"+e.getValue().formatForInput(rjb).getContentLength());
+ RestJob rjb = new RestJob(0, new RestJobThread(rc),
+ rc.av.getAlignment(), null);
+ rjb.setAlignmentForInputs(rc.service.getInputParams().values(),
+ rc.av.getAlignment());
+ for (Map.Entry<String, InputType> e : rc.service.getInputParams()
+ .entrySet())
+ {
+ System.out.println("For Input '" + e.getKey() + ":\n"
+ + e.getValue().formatForInput(rjb).getContentLength());
}
}