def test_complex_output(self): complexo = ComplexOutput("complex", "Complex foo", [Format("GML")]) doc = complexo.describe_xml() [outpt] = xpath_ns(doc, "/Output") [default] = xpath_ns(doc, "/Output/ComplexOutput/Default/Format/MimeType") supported = xpath_ns(doc, "/Output/ComplexOutput/Supported/Format/MimeType") assert default.text == "application/gml+xml" assert len(supported) == 1
def test_complex_output(self): complexo = ComplexOutput('complex', 'Complex foo', [Format('GML')]) doc = complexo.describe_xml() [outpt] = xpath_ns(doc, '/Output') [default] = xpath_ns(doc, '/Output/ComplexOutput/Default/Format/MimeType') supported = xpath_ns(doc, '/Output/ComplexOutput/Supported/Format/MimeType') assert default.text == 'application/gml+xml' assert len(supported) == 1
def test_complex_output(self): complexo = ComplexOutput('complex', 'Complex foo', [Format('GML')], keywords=['kw1', 'kw2']) doc = complexo.describe_xml() [outpt] = xpath_ns(doc, '/Output') [default] = xpath_ns(doc, '/Output/ComplexOutput/Default/Format/MimeType') supported = xpath_ns(doc, '/Output/ComplexOutput/Supported/Format/MimeType') assert default.text == 'application/gml+xml' assert len(supported) == 1 [keywords] = xpath_ns(doc, '/Output/ows:Keywords') kws = xpath_ns(keywords, './ows:Keyword') assert keywords is not None assert len(kws) == 2