public class BasicParserPoolTest extends Object
NamespaceSupport| Modifier and Type | Class and Description |
|---|---|
static class |
BasicParserPoolTest.MockEntityResolver |
static class |
BasicParserPoolTest.MockErrorHandler |
| Modifier and Type | Field and Description |
|---|---|
private net.shibboleth.utilities.java.support.xml.BasicParserPool |
basicParserPool |
private static String |
DTD_FILE |
(package private) int |
maxPoolSize
Max size of the pool we're using.
|
private static String |
SCHEMA_FILE |
private static String |
TEST_DIR |
private static String |
XML_FILE |
| Constructor and Description |
|---|
BasicParserPoolTest() |
| Modifier and Type | Method and Description |
|---|---|
private void |
checkParsedDocument(Document document) |
void |
setupEachTest() |
private void |
testDeadBuilder(DocumentBuilder builder) |
void |
testDestroy() |
void |
testDTD() |
void |
testExplicitMultipleReturn()
Test for caller (illegally) returning a builder multiple times to pool.
|
void |
testFinalize()
Test issue reported in JXT-46 - a parser should not be checked into the pool multiple times
via the auto-checkin mechanism by the proxy finalize().
|
void |
testGetReturn() |
void |
testInit() |
void |
testMaxPoolSize()
Test that only maxPoolSize parsers are ever cached.
|
void |
testNewDocument() |
void |
testParams() |
void |
testParse() |
void |
testParserUseAfterReturn()
Test for a caller illegally using a parser proxy after it has been returned.
|
private static final String TEST_DIR
private static final String SCHEMA_FILE
private static final String XML_FILE
private static final String DTD_FILE
private net.shibboleth.utilities.java.support.xml.BasicParserPool basicParserPool
int maxPoolSize
public void setupEachTest()
public void testParams()
throws SAXException,
net.shibboleth.utilities.java.support.component.ComponentInitializationException,
net.shibboleth.utilities.java.support.xml.XMLParserException,
IOException
SAXExceptionnet.shibboleth.utilities.java.support.component.ComponentInitializationExceptionnet.shibboleth.utilities.java.support.xml.XMLParserExceptionIOExceptionpublic void testInit()
throws net.shibboleth.utilities.java.support.component.ComponentInitializationException,
SAXException,
net.shibboleth.utilities.java.support.xml.XMLParserException,
IOException
net.shibboleth.utilities.java.support.component.ComponentInitializationExceptionSAXExceptionnet.shibboleth.utilities.java.support.xml.XMLParserExceptionIOExceptionpublic void testDestroy()
throws net.shibboleth.utilities.java.support.component.ComponentInitializationException,
SAXException,
IOException
net.shibboleth.utilities.java.support.component.ComponentInitializationExceptionSAXExceptionIOExceptionprivate void checkParsedDocument(Document document)
public void testParse()
throws IOException,
net.shibboleth.utilities.java.support.component.ComponentInitializationException,
net.shibboleth.utilities.java.support.xml.XMLParserException,
FileNotFoundException
IOExceptionnet.shibboleth.utilities.java.support.component.ComponentInitializationExceptionnet.shibboleth.utilities.java.support.xml.XMLParserExceptionFileNotFoundExceptionpublic void testDTD()
throws IOException,
net.shibboleth.utilities.java.support.component.ComponentInitializationException,
net.shibboleth.utilities.java.support.xml.XMLParserException,
FileNotFoundException
IOExceptionnet.shibboleth.utilities.java.support.component.ComponentInitializationExceptionnet.shibboleth.utilities.java.support.xml.XMLParserExceptionFileNotFoundExceptionpublic void testNewDocument()
throws net.shibboleth.utilities.java.support.component.ComponentInitializationException,
net.shibboleth.utilities.java.support.xml.XMLParserException
net.shibboleth.utilities.java.support.component.ComponentInitializationExceptionnet.shibboleth.utilities.java.support.xml.XMLParserExceptionprivate void testDeadBuilder(DocumentBuilder builder)
public void testGetReturn()
throws net.shibboleth.utilities.java.support.component.ComponentInitializationException,
net.shibboleth.utilities.java.support.xml.XMLParserException
net.shibboleth.utilities.java.support.component.ComponentInitializationExceptionnet.shibboleth.utilities.java.support.xml.XMLParserExceptionpublic void testFinalize()
throws net.shibboleth.utilities.java.support.xml.XMLParserException,
net.shibboleth.utilities.java.support.component.ComponentInitializationException
XMLParserExceptionnet.shibboleth.utilities.java.support.component.ComponentInitializationExceptionInterruptedExceptionpublic void testExplicitMultipleReturn()
throws net.shibboleth.utilities.java.support.xml.XMLParserException,
net.shibboleth.utilities.java.support.component.ComponentInitializationException
XMLParserExceptionnet.shibboleth.utilities.java.support.component.ComponentInitializationExceptionpublic void testParserUseAfterReturn()
throws net.shibboleth.utilities.java.support.xml.XMLParserException,
URISyntaxException,
net.shibboleth.utilities.java.support.component.ComponentInitializationException
XMLParserExceptionURISyntaxExceptionnet.shibboleth.utilities.java.support.component.ComponentInitializationExceptionIOExceptionpublic void testMaxPoolSize()
throws net.shibboleth.utilities.java.support.xml.XMLParserException,
net.shibboleth.utilities.java.support.component.ComponentInitializationException
XMLParserExceptionnet.shibboleth.utilities.java.support.component.ComponentInitializationExceptionCopyright © 1999–2019 Shibboleth Consortium. All rights reserved.