OWLOntology ont2 = super.roundTripOntology(ont, format);
OWLDocumentFormat ont2Format = ont2.getOWLOntologyManager()
.getOntologyFormat(ont2);
if (format instanceof PrefixDocumentFormat
&& ont2Format instanceof PrefixDocumentFormat) {
PrefixDocumentFormat prefixFormat = (PrefixDocumentFormat) format;
prefixFormat.getPrefixName2PrefixMap();
PrefixDocumentFormat prefixFormat2 = (PrefixDocumentFormat) ont2Format;
for (String prefixName : prefixFormat.getPrefixNames()) {
assert prefixName != null;
assertTrue(prefixFormat2.containsPrefixMapping(prefixName));
assertEquals(prefixFormat.getPrefix(prefixName),
prefixFormat2.getPrefix(prefixName));
}
}
return ont2;
}