private void abstactAskService(final String... args) throws IOException {
  setMethodisPostUrlEncodedData();
  serviceRequest("update","PREFIX eg: <http://example.com/a#> INSERT { eg:a eg:p \"rs123\" ; eg:q 123, 100 } WHERE {}");
  final StringBuilder bld=new StringBuilder();
  bld.append("base <");
  bld.append(m_serviceURL);
  bld.append("/sparql>");
  for (  String arg : args) {
    bld.append('\n');
    bld.append(arg);
  }
  if (log.isInfoEnabled())   log.info(bld.toString());
  final String result=serviceRequest("query",bld.toString());
  if (log.isInfoEnabled())   log.info(result);
  assertTrue(result.contains("true"));
}

private void abstactAskService ( final String ... args ) throws IOException { setMethodisPostUrlEncodedData ( ) ; serviceRequest ( "update" , "PREFIX eg: <http://example.com/a#> INSERT { eg:a eg:p \"rs123\" ; eg:q 123, 100 } WHERE {}" ) ; final StringBuilder bld = new StringBuilder ( ) ; bld . append ( "base <" ) ; bld . append ( m_serviceURL ) ; bld . append ( "/sparql>" ) ; for ( String arg : args ) { bld . append ( '\n' ) ; bld . append ( arg ) ; } if ( log . isInfoEnabled ( ) ) log . info ( bld . toString ( ) ) ; final String result = serviceRequest ( "query" , bld . toString ( ) ) ; if ( log . isInfoEnabled ( ) ) log . info ( result ) ; assertTrue ( result . contains ( "true" ) ) ; }
execute an ask query including a service keyword which gets sent back to this server . the test succeeeds if the query returns true , and fails otherwise
