コード例 #1
0
  @Test
  public void testServerSearchByAttributeSetCommand() throws Exception {
    g = loadOntology("../OWLTools-Sim/src/test/resources/sim/mp-subset-1.obo");

    ABoxUtils.createRandomClassAssertions(g.getSourceOntology(), 200, 20);

    OwlSimFactory owlSimFactory = new FastOwlSimFactory();
    OwlSim sos = owlSimFactory.createOwlSim(g.getSourceOntology());

    sos.createElementAttributeMapFromOntology();

    final HttpUriRequest httppost = createSearchByAttributeSetRequest(5);
    runServerCommunication(httppost, sos);
  }
コード例 #2
0
  @Test
  public void testServerGetAnnotationSufficiencyScoreCommandBad() throws Exception {
    g = loadOntology("../OWLTools-Sim/src/test/resources/sim/mp-subset-1.obo");

    ABoxUtils.createRandomClassAssertions(g.getSourceOntology(), 200, 20);
    // set sim
    OwlSimFactory owlSimFactory = new FastOwlSimFactory();
    OwlSim sos = owlSimFactory.createOwlSim(g.getSourceOntology());

    sos.createElementAttributeMapFromOntology();

    HttpUriRequest httppost = createBogusAnnotSufRequest(5);

    runServerCommunication(httppost, sos);
  }