Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

unit tests are failing... #1

Closed
stdotjohn opened this issue Mar 2, 2014 · 2 comments
Closed

unit tests are failing... #1

stdotjohn opened this issue Mar 2, 2014 · 2 comments
Labels

Comments

@stdotjohn
Copy link
Member

It looks like there is a dependency on the co-ode pizza ontology.

testIRIMapper(org.protege.xmlcatalog.owlapi.IRIMapperTest) Time elapsed: 1.108 sec <<< FAILURE! org.semanticweb.owlapi.model.UnloadableImportException: Could not load imported ontology: http://test.org/TestPizzaImport.owl Cause: http://www.co-ode.org/ontologies/pizza/pizza.owl at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1624) at sun.net.www.protocol.http.HttpURLConnection.getHeaderField(HttpURLConnection.java:2678) at java.net.URLConnection.getContentEncoding(URLConnection.java:533) at org.semanticweb.owlapi.io.AbstractOWLParser.getInputStream(AbstractOWLParser.java:131) at org.semanticweb.owlapi.io.AbstractOWLParser.getInputSource(AbstractOWLParser.java:206) at org.coode.owlapi.rdfxml.parser.RDFXMLParser.parse(RDFXMLParser.java:118) at uk.ac.manchester.cs.owl.owlapi.ParsableOWLOntologyFactory.loadOWLOntology(ParsableOWLOntologyFactory.java:206) at uk.ac.manchester.cs.owl.owlapi.OWLOntologyManagerImpl.loadOntology(OWLOntologyManagerImpl.java:880) at uk.ac.manchester.cs.owl.owlapi.OWLOntologyManagerImpl.loadOntology(OWLOntologyManagerImpl.java:800) at uk.ac.manchester.cs.owl.owlapi.OWLOntologyManagerImpl.loadImports(OWLOntologyManagerImpl.java:1278) at uk.ac.manchester.cs.owl.owlapi.OWLOntologyManagerImpl.makeLoadImportRequest(OWLOntologyManagerImpl.java:1309) at org.coode.owlapi.owlxmlparser.OWLImportsHandler.endElement(OWLImportsHandler.java:68) at org.coode.owlapi.owlxmlparser.OWLXMLParserHandler.endElement(OWLXMLParserHandler.java:1030) at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.endElement(AbstractSAXParser.java:609) at com.sun.org.apache.xerces.internal.impl.dtd.XMLNSDTDValidator.endNamespaceScope(XMLNSDTDValidator.java:266) at com.sun.org.apache.xerces.internal.impl.dtd.XMLDTDValidator.handleEndElement(XMLDTDValidator.java:2005) at com.sun.org.apache.xerces.internal.impl.dtd.XMLDTDValidator.endElement(XMLDTDValidator.java:879) at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanEndElement(XMLDocumentFragmentScannerImpl.java:1789) at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:2965) at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:606) at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(XMLNSDocumentScannerImpl.java:117) at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:510) at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:848) at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:777) at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:141) at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1213) at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:649) at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl.parse(SAXParserImpl.java:333) at org.coode.owlapi.owlxmlparser.OWLXMLParser.parse(OWLXMLParser.java:89) at uk.ac.manchester.cs.owl.owlapi.ParsableOWLOntologyFactory.loadOWLOntology(ParsableOWLOntologyFactory.java:206) at uk.ac.manchester.cs.owl.owlapi.OWLOntologyManagerImpl.loadOntology(OWLOntologyManagerImpl.java:880) at uk.ac.manchester.cs.owl.owlapi.OWLOntologyManagerImpl.loadOntology(OWLOntologyManagerImpl.java:800) at uk.ac.manchester.cs.owl.owlapi.OWLOntologyManagerImpl.loadOntology(OWLOntologyManagerImpl.java:758) at org.protege.xmlcatalog.owlapi.IRIMapperTest.testIRIMapper(IRIMapperTest.java:24)
@stdotjohn stdotjohn added the bug label Mar 2, 2014
@jvendetti
Copy link
Member

Hi Tim. I modified the URI for the pizza ontology in the redirect-to-pizza catalog file. This fixes the UnloadableImportException. However, now the assertEquals method on line 32 of IRIMapperTest fails. If we load the pizza ontology from http://protege.stanford.edu/ontologies/pizza/pizza.owl, the OntologyIRI and OntologyDocumentIRI don't match, whereas they did before. Should this line simply be removed?

@stdotjohn
Copy link
Member Author

The test demonstrates that the XMLCatalogIRIMapper will redirect imports as directed by the redirect-to-pizza.xml file. So line 32 needs to be set to match the value that was put in the redirect-to-pizza.xml file and the line 31 needs to match the IRI of the pizza ontology as specified in the pizza ontology file.

Now I will see if I can reference both our commits when I close the bug...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants