@@ -866,6 +866,59 @@ def test_wms_getmap_filter_ogc_with_empty(self):
866
866
r , h = self ._result (self ._execute_request (qs ))
867
867
self ._img_diff_error (r , h , "WMS_GetMap_Filter_OGC3" )
868
868
869
+ def test_wms_getmap_filter_ogc_v2 (self ):
870
+ # with namespace
871
+ filter = ('<fes:Filter xmlns:fes=\" http://www.opengis.net/fes/2.0\" >'
872
+ '<fes:PropertyIsEqualTo>'
873
+ '<fes:ValueReference>name</fes:ValueReference>'
874
+ '<fes:Literal>eurasia</fes:Literal>'
875
+ '</fes:PropertyIsEqualTo>'
876
+ '</fes:Filter>' )
877
+
878
+ qs = "?" + "&" .join (["%s=%s" % i for i in list ({
879
+ "MAP" : urllib .parse .quote (self .projectPath ),
880
+ "SERVICE" : "WMS" ,
881
+ "VERSION" : "1.1.1" ,
882
+ "REQUEST" : "GetMap" ,
883
+ "LAYERS" : "Country,Hello" ,
884
+ "STYLES" : "" ,
885
+ "FORMAT" : "image/png" ,
886
+ "BBOX" : "-16817707,-4710778,5696513,14587125" ,
887
+ "HEIGHT" : "500" ,
888
+ "WIDTH" : "500" ,
889
+ "CRS" : "EPSG:3857" ,
890
+ "FILTER" : filter
891
+ }.items ())])
892
+
893
+ r , h = self ._result (self ._execute_request (qs ))
894
+ self ._img_diff_error (r , h , "WMS_GetMap_Filter_OGC_V2" )
895
+
896
+ # without namespace (only with prefix)
897
+ filter = ('<fes:Filter>'
898
+ '<fes:PropertyIsEqualTo>'
899
+ '<fes:ValueReference>name</fes:ValueReference>'
900
+ '<fes:Literal>eurasia</fes:Literal>'
901
+ '</fes:PropertyIsEqualTo>'
902
+ '</fes:Filter>' )
903
+
904
+ qs = "?" + "&" .join (["%s=%s" % i for i in list ({
905
+ "MAP" : urllib .parse .quote (self .projectPath ),
906
+ "SERVICE" : "WMS" ,
907
+ "VERSION" : "1.1.1" ,
908
+ "REQUEST" : "GetMap" ,
909
+ "LAYERS" : "Country,Hello" ,
910
+ "STYLES" : "" ,
911
+ "FORMAT" : "image/png" ,
912
+ "BBOX" : "-16817707,-4710778,5696513,14587125" ,
913
+ "HEIGHT" : "500" ,
914
+ "WIDTH" : "500" ,
915
+ "CRS" : "EPSG:3857" ,
916
+ "FILTER" : filter
917
+ }.items ())])
918
+
919
+ r , h = self ._result (self ._execute_request (qs ))
920
+ self ._img_diff_error (r , h , "WMS_GetMap_Filter_OGC_V2" )
921
+
869
922
def test_wms_getmap_selection (self ):
870
923
qs = "?" + "&" .join (["%s=%s" % i for i in list ({
871
924
"MAP" : urllib .parse .quote (self .projectPath ),
0 commit comments