@Test
public void testGetInputStream() throws Exception, BadFetchError {

    final MappedDocumentStrategy strategy = new MappedDocumentStrategy();
    JVoiceXMLEvent error = null;
    try {
        strategy.getInputStream(null, null, null, 0, null);
    } catch (BadFetchError e) {
        error = e;
    }
    Assert.assertNotNull("BadFetchError expected", error);
    URI uri1 = map.getUri("/doc");
    final InputStream stream1 = strategy.getInputStream(null, uri1, null,
            0, null);
    Assert.assertNotNull(stream1);
    final InputSource inputSource = new InputSource(stream1);
    final VoiceXmlDocument doc1 = new VoiceXmlDocument(inputSource);
    final Vxml vxml1 = doc1.getVxml();
    Assert.assertTrue(vxml1.hasChildNodes());
    URI uri2 =  map.getUri("/test");
    final InputStream stream2 = strategy.getInputStream(null, uri2, null,
            0, null);
    Assert.assertNotNull(stream2);
    final String test = readString(stream2);
    Assert.assertEquals("test", test);
}