| jena.test.Test_schemagen
Test_schemagen | public class Test_schemagen extends TestCase (Code) | |
Unit tests for schemagen
author: Ian Dickinson, HP Labs author: (email) version: CVS $Id: Test_schemagen.java,v 1.8 2008/01/02 12:08:49 andy_seaborne Exp $ |
Inner Class :static class SchemaGenAux extends schemagen | |
getClassPath | protected String getClassPath(File tmpDir)(Code) | | answer the classpath we can use to compile the sg output files
Parameters: tmpDir - |
testCompile | protected void testCompile(String source, String className) throws Exception(Code) | | Test the compilability of the generated output string by saving it to a
class file, and invoking javac on that file.
Parameters: source - Parameters: className - throws: Exception - |
testNoBaseURI0 | public void testNoBaseURI0() throws Exception(Code) | | This test used to fail with an abort, but we now guess the NS based on prevalence
|
testRC0 | public void testRC0() throws Exception(Code) | | Bug report by Richard Cyganiak
|
testSchemagenOutput | protected String testSchemagenOutput(String source, SchemaGenAux sg, String[] args, String[] posPatterns, String[] negPatterns) throws Exception(Code) | | Test the output from schemagen by saving the output to a string,
then ensuring that every positive regex matches at least one line, and
every negative regex matches at most no lines. Also checks that
compiling the file does not cause any errors.
Parameters: source - String defining the model, using N3 Parameters: sg - The schemagen object to test, or null for a default Parameters: args - list of args to pass to SG Parameters: posPatterns - array of regexps that must match at least once in the output Parameters: negPatterns - arrays of regexps that must not match the output The string defining the java class |
testStrictIndividuals0 | public void testStrictIndividuals0() throws Exception(Code) | | |
testStrictIndividuals1 | public void testStrictIndividuals1() throws Exception(Code) | | |
|
|