Skip to content
Permalink
Browse files

Use new query API for style test

  • Loading branch information...
geographika committed Oct 10, 2018
1 parent 693ac0f commit ce97bc8607cab6f2d2fbf9ca005f839ad8d81d89
Showing with 5 additions and 2 deletions.
  1. +5 −2 mapscript/python/tests/cases/style_test.py
@@ -178,7 +178,7 @@ def testInsertNULLStyle(self):

class BrushCachingTestCase(MapTestCase):

def xtestDrawMapWithSecondPolygon(self):
def testDrawMapWithSecondPolygon(self):
"""draw a blue polygon and a red polygon"""
p = self.map.getLayerByName('POLYGON')
ip = mapscript.layerObj(self.map)
@@ -197,7 +197,10 @@ def xtestDrawMapWithSecondPolygon(self):
# pull out the first feature from polygon layer, shift it
# and use this as an inline feature in new layer
p.open()
s0 = p.getFeature(0)
p.template = "FAKE" # set a template so the layer can be queried
p.queryByIndex(self.map, -1, 0, mapscript.MS_TRUE)
res = p.getResult(0)
s0 = p.getShape(res)
p.close()
r0 = s0.bounds
r1 = mapscript.rectObj(r0.minx-0.1, r0.miny-0.1, r0.maxx-0.1, r0.maxy-0.1)

0 comments on commit ce97bc8

Please sign in to comment.
You can’t perform that action at this time.