@Test
public void testExtractNamedElement() {

    final String elementName = "ImportantQuestion";
    
    assertEquals(contents, extractNonEmptyElement(envelopeWithNamespacePrefixes, elementName));
    assertEquals(contents, extractNonEmptyElement(envelopeWithoutNamespacePrefixes, elementName));
    assertEquals(null, extractNonEmptyElement(emptyEnvelopeWithNamespacePrefixes, elementName));
    assertEquals(null, extractNonEmptyElement(emptyEnvelopeWithoutNamespacePrefixes, elementName));
    assertEquals(null, extractNonEmptyElement(emptyEnvelopeWithNamespacePrefixesShort, elementName));
    assertEquals(null, extractNonEmptyElement(emptyEnvelopeWithoutNamespacePrefixesShort, elementName));
    Assert.assertNull(extractNonEmptyElement(null, elementName));
    Assert.assertNull(extractNonEmptyElement(totallyBad, elementName));
}