From 5f375eb30af5bc64c3310a7d9c225a5a2fd89702 Mon Sep 17 00:00:00 2001 From: zmiao Date: Thu, 6 Feb 2020 15:36:36 +0200 Subject: [PATCH 1/3] Add expression and render tests for within expression --- test/ignores.json | 8 +- .../expression-tests/within/basic/test.json | 56 +++++++++ .../filter-with-inlined-geojson/expected.png | Bin 0 -> 321 bytes .../filter-with-inlined-geojson/style.json | 100 ++++++++++++++++ .../within/layout-text/expected.png | Bin 0 -> 1156 bytes .../within/layout-text/style.json | 110 ++++++++++++++++++ .../within/paint-circle/expected.png | Bin 0 -> 594 bytes .../within/paint-circle/style.json | 101 ++++++++++++++++ .../within/paint-icon/expected.png | Bin 0 -> 835 bytes .../render-tests/within/paint-icon/style.json | 104 +++++++++++++++++ .../within/paint-text/expected.png | Bin 0 -> 1700 bytes .../render-tests/within/paint-text/style.json | 108 +++++++++++++++++ 12 files changed, 586 insertions(+), 1 deletion(-) create mode 100644 test/integration/expression-tests/within/basic/test.json create mode 100644 test/integration/render-tests/within/filter-with-inlined-geojson/expected.png create mode 100644 test/integration/render-tests/within/filter-with-inlined-geojson/style.json create mode 100644 test/integration/render-tests/within/layout-text/expected.png create mode 100644 test/integration/render-tests/within/layout-text/style.json create mode 100644 test/integration/render-tests/within/paint-circle/expected.png create mode 100644 test/integration/render-tests/within/paint-circle/style.json create mode 100644 test/integration/render-tests/within/paint-icon/expected.png create mode 100644 test/integration/render-tests/within/paint-icon/style.json create mode 100644 test/integration/render-tests/within/paint-text/expected.png create mode 100644 test/integration/render-tests/within/paint-text/style.json diff --git a/test/ignores.json b/test/ignores.json index 6358e1aa291..1f2bb302e6e 100644 --- a/test/ignores.json +++ b/test/ignores.json @@ -18,5 +18,11 @@ "render-tests/text-variable-anchor/all-anchors-tile-map-mode": "skip - mapbox-gl-js does not need to render tiles", "render-tests/fill-pattern/update-feature-state": "https://github.com/mapbox/mapbox-gl-js/issues/7207", "render-tests/text-size/zero": "https://github.com/mapbox/mapbox-gl-js/issues/9161", - "render-tests/text-variable-anchor/left-top-right-buttom-offset-tile-map-mode": "skip - mapbox-gl-js does not need to render tiles" + "render-tests/text-variable-anchor/left-top-right-buttom-offset-tile-map-mode": "skip - mapbox-gl-js does not need to render tiles", + "render-tests/within/filter-with-inlined-geojson" : "skip - TODO: Within Expression needs to be implemented in mapbox-gl-js", + "render-tests/within/layout-text" : "skip - TODO: Within Expression needs to be implemented in mapbox-gl-js", + "render-tests/within/paint-circle" : "skip - TODO: Within Expression needs to be implemented in mapbox-gl-js", + "render-tests/within/paint-icon" : "skip - TODO: Within Expression needs to be implemented in mapbox-gl-js", + "render-tests/within/paint-text" : "skip - TODO: Within Expression needs to be implemented in mapbox-gl-js", + "expression-tests/within/basic" : "skip - TODO: Within Expression needs to be implemented in mapbox-gl-js" } diff --git a/test/integration/expression-tests/within/basic/test.json b/test/integration/expression-tests/within/basic/test.json new file mode 100644 index 00000000000..a710b5c1c32 --- /dev/null +++ b/test/integration/expression-tests/within/basic/test.json @@ -0,0 +1,56 @@ +{ + "expression": ["within", { + "type": "Polygon", + "coordinates": [[[0, 0], [0, 5], [5, 5], [5, 0], [0, 0]]] + }], + "inputs": [[{ + "zoom": 3, + "canonicalID": { + "z": 3, + "x": 3, + "y": 3 + } + }, { + "geometry": { + "type": "Point", + "coordinates": [6, 6] + } + }], [{ + "zoom": 3, + "canonicalID": { + "z": 3, + "x": 3, + "y": 3 + } + }, { + "geometry": { + "type": "Point", + "coordinates": [2, 2] + } + }], [{ + "zoom": 3, + "canonicalID": { + "z": 3, + "x": 3, + "y": 3 + } + }, { + "geometry": { + "type": "LineString", + "coordinates": [[3, 3], [4, 1]] + } + }]], + "expected": { + "compiled": { + "type": "boolean", + "isFeatureConstant": false, + "isZoomConstant": true, + "result": "success" + }, + "outputs": [false, true, false], + "serialized": ["Within", { + "coordinates": [[[0, 0], [0, 5], [5, 5], [5, 0], [0, 0]]], + "type": "Polygon" + }] + } +} diff --git a/test/integration/render-tests/within/filter-with-inlined-geojson/expected.png b/test/integration/render-tests/within/filter-with-inlined-geojson/expected.png new file mode 100644 index 0000000000000000000000000000000000000000..17525dffae02437d8a68b744b23ed600cf9c0fa2 GIT binary patch literal 321 zcmeAS@N?(olHy`uVBq!ia0vp^4j|0I1|(Ny7T#lEVC3+0aSW-L^Y*GC*C7W1x5QkP zwMzt4y0358bkgxn5#QDer`$d;RIwgBq|G7ph0Cp3VVWb0d+?HgrduF^RdknvA7oNE5njPy5&D`Sie_0kR-eL)~1vfZQ&d`*gx2{^`xaX3KH%?X9{FHBq zdaLj<`25d*LG})-x1O@K%Ql(yimjrwW|rZ^xCV=N`&n0noU3BgoBl4kA?xcBafP!p z?s_+rRWFoQ;As!ii!bi?-|uRDT%2QqV#U3G4}YW;=YIUr#JFkF67@in4K+Jl8}5U` c0t+ZAWA^s9&xxsi;sKKNboFyt=akR{0CLxIeEc7Q*%QM%Z+EKciH~w?g+R)uc zA6L5_d)ZsB(DJ2yo8_FXay;ql^0#!~`h5LEsr>bQm!xd><)_TK_apXJYVOvs*e^F? z-tM`!{%ZF1*2nX%9#idGefe63_o3(I*}u2$-@g~!Rd-EkO`QN5|Sp44nZC|3? z`fK+t>t*WR@_ndN5;J>_#XGsT{%;R|P~PCZd%?_abH8ofws_BZzLlOV7gygkIAl26 zN#*Tgp4C_`l4Q_cIkkt2U>%XY876f2*snGEn+ToLp|i!}n#aug%tN z)at$WW%r@k^&z_pTax3rKdx2K>G9g}!fx5z%kN~KeJs4?{!r@m#{V3zPtEM#AaGgw zzTlzGe`_?W-n{&9{>Uq_k#@hG&F!_`dwj zX|kI`SKmA9;LYB4;?p_V5s#0@Z#j3)yuB}a-=AiuoU>g~QJ6Y!i)5S6#n+TmF6D2+^hu4eSh$eJ^Sl}AAbJ%dH4EXvXA!F&TZYFpKa|CVHrMY!zTMfTIPqE zxJgId0@vhnqx-&FCN6c*|Fvk3{@d#kNb!h+IbmHrV^5iBwD0Xz^FT^GUHx3vIVCg! E04yOI!Tk+rtSy zic2~cO!ekSVa+?B+u_YA#Lb<}D($V>yV4|L9Y;yT^BJ_ug~9bbHkP zuPe?RstWs_(fQpkBHSm!g`=AzQBYAwsl~NrLx+Hv;2|X^q6L+Nt{pqpf2sCMO>}g8 zi>cAx_EM`AmuLI%wVEpJZQHu7?92HLyK?jDM6Y>#k-D~M#WUe+7GK1!{rgv(Sh#5W zhGmzJAA01HpIEwEW7XHM^AAaN#vQ(Ov$B?V|Js(TPU{m(Z{NFTEq>+ItHQ%8fCBFm z&z2W_Sn}rGz6_Zu8=^W}OZTd+S*=F0(`U4P-SqCI(EG_7q*nC*OSpOcS1%)4_(8cD Zulc3f3O0DW^>G4;c)I$ztaD0e0szN~`E39I literal 0 HcmV?d00001 diff --git a/test/integration/render-tests/within/paint-circle/style.json b/test/integration/render-tests/within/paint-circle/style.json new file mode 100644 index 00000000000..5de2bdd2bd4 --- /dev/null +++ b/test/integration/render-tests/within/paint-circle/style.json @@ -0,0 +1,101 @@ +{ + "version": 8, + "metadata": { + "test": { + "width": 150, + "height": 150 + } + }, + "zoom": 3, + "center": [3, 3], + "sources": { + "points": { + "type": "geojson", + "data": { + "type": "FeatureCollection", + "features": [ + { + "type": "Feature", + "properties": { + }, + "geometry": { + "type": "Point", + "coordinates": [ + 1.9775390625, + 2.3284603685731593 + ] + } + }, + { + "type": "Feature", + "properties": { + }, + "geometry": { + "type": "Point", + "coordinates": [ + 2.021484375, + 7.798078531355303 + ] + } + } + ] + } + }, + "polygon": { + "type": "geojson", + "data": { + "type": "FeatureCollection", + "features": [ + { + "type": "Feature", + "properties": {}, + "geometry": { + "type": "Polygon", + "coordinates": [ + [ + [0, 0], + [0, 5], + [5, 5], + [5, 0], + [0, 0] + ] + ] + } + } + ] + } + } + }, + "layers": [ + { + "id": "boarder", + "type": "fill", + "source": "polygon", + "paint": { + "fill-color": "white", + "fill-opacity": 0.5 + } + }, + { + "id": "circle", + "type": "circle", + "source": "points", + "paint": { + "circle-radius": 5, + "circle-color": ["case", ["within", { + "type": "Polygon", + "coordinates": [ + [ + [0, 0], + [0, 5], + [5, 5], + [5, 0], + [0, 0] + ] + ] + } + ], "red", "blue"] + } + } + ] +} diff --git a/test/integration/render-tests/within/paint-icon/expected.png b/test/integration/render-tests/within/paint-icon/expected.png new file mode 100644 index 0000000000000000000000000000000000000000..ba7e825690c683f1acc3e7186c64fc266dd147da GIT binary patch literal 835 zcmeAS@N?(olHy`uVBq!ia0vp^(?FPm4M^HB7CvHNVCM34aSW-L^Y+fg?66Xq_^@Cv&LiA3N|tOU0wBr`0^s!n0OH_yDKzBKsJ+~Yj2o!(Bqq*?gM@bIivwLw;@ z$EMByBPV)wed_t^cA9gA*H8Pq%`4>lX|?S66V63dS?!4`%m1nQ@%*Osr`1lmWzFyN zi~d!7Zs8{J(|pryLw~!#91NiyuDcw$v0?o;+3$Wkzf3=Er~f;n!#w_5$=luUras+p zZrWbEBfldevV9_!2#9I6xN;>hEVQiqp*0)a*Ki)$Mv$uH=7oZSCbl zuV#iF-c|82=FQ#T&N;Wfl$+S^x_PXZKdI)=@})OguF9`%E&cgvx1rg$)B7F&mRpzq zlQTAc-g;FSDE{Qc*3iXKHyfF+Cnr9fvY~3h)D3xeDzwYq?y@yllY9H!(W%;|aw08T zuSIcY=jB(t3_Fxn_TfP} z^Wj^2e?RwHF9*`jy}EMlhZX&Y&(0Q4F8XwsE0A+_+qFYk*IG8${{C+-v^_7jywzfzBW4?nbO>DLWm*Z!2P`h3nS;I89gix9`$C=>R1e!{Z$isD177R3D0KD_T%IS*>A!gvm`{~09i VRGqH7!@3V7=IQF^vd$@?2>@<;h57&h literal 0 HcmV?d00001 diff --git a/test/integration/render-tests/within/paint-icon/style.json b/test/integration/render-tests/within/paint-icon/style.json new file mode 100644 index 00000000000..afae9dfb04e --- /dev/null +++ b/test/integration/render-tests/within/paint-icon/style.json @@ -0,0 +1,104 @@ +{ + "version": 8, + "metadata": { + "test": { + "width": 150, + "height": 150 + } + }, + "zoom": 3, + "center": [3, 3], + "sources": { + "points": { + "type": "geojson", + "data": { + "type": "FeatureCollection", + "features": [ + { + "type": "Feature", + "properties": { + }, + "geometry": { + "type": "Point", + "coordinates": [ + 1.9775390625, + 2.3284603685731593 + ] + } + }, + { + "type": "Feature", + "properties": { + }, + "geometry": { + "type": "Point", + "coordinates": [ + 2.021484375, + 7.798078531355303 + ] + } + } + ] + } + }, + "polygon": { + "type": "geojson", + "data": { + "type": "FeatureCollection", + "features": [ + { + "type": "Feature", + "properties": {}, + "geometry": { + "type": "Polygon", + "coordinates": [ + [ + [0, 0], + [0, 5], + [5, 5], + [5, 0], + [0, 0] + ] + ] + } + } + ] + } + } + }, + "sprite": "local://sprites/sprite", + "layers": [ + { + "id": "boarder", + "type": "fill", + "source": "polygon", + "paint": { + "fill-color": "white", + "fill-opacity": 0.5 + } + }, + { + "id": "symbol", + "type": "symbol", + "source": "points", + "layout": { + "icon-image": "dot.sdf" + }, + "paint" : { + "icon-color": ["case", ["within", { + "type": "Polygon", + "coordinates": [ + [ + [0, 0], + [0, 5], + [5, 5], + [5, 0], + [0, 0] + ] + ] + } + ], "red", "blue"] + } + } + ] +} diff --git a/test/integration/render-tests/within/paint-text/expected.png b/test/integration/render-tests/within/paint-text/expected.png new file mode 100644 index 0000000000000000000000000000000000000000..d9fdd1b9a4c3ace9d588d91350a7b3b3870a608d GIT binary patch literal 1700 zcmbVLc~H^`6t?Zy(p=m1Xf@L;TSZ-ujMPNjEG@hf7{4ii_+p9&&| z-JcJNX}7`G;NvJRPvVCp$?;~C@9MS6$+;Dn3U4dnDWR9YF$gI%BQ}5xiFZl) zstKVwJq=<~c=lwK)Yv)GeIoJY5>!EeM04GS2`0V0E8<`3Wm(3)d8~H&o>BFFkt>4} zNv-RXh$pR5ZBuy_`cUoh3u2xr7>% zK+`dd_0>vz;p|O{)nHkdbv|2~;SHEKGX~O|^2z+tjU|xnm_!BlmWioph3fpagoJfe#&vwEO@o~L3zakz;t%eJNZ!ZFM!EA)x~Xdn8vFB94Krx z*Fost)qB0gRgwgwPo9RM215ot2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Ru|aHWw`PZMr9Trq}w=)MSUBi)X;qpXN- zG<3{HfIt|@#8JibgM89i6=0;hKpvybDewmUnk^xleJtGEgz=73*uH^JF}SVW)-2wP z8{Gx}m=Y&`r6e>J7Qcuf1uVnWoi*4VLzdd-S*IzPU~E6JNspP`p}EUE~a#!e-yU;Yh> Date: Fri, 7 Feb 2020 12:28:23 +0200 Subject: [PATCH 2/3] Add error case for within expression test. Narrow render tests camera size --- test/ignores.json | 3 +- .../within/invalid-geojson/test.json | 52 ++++++++++++++++++ .../within/layout-text/expected.png | Bin 1156 -> 628 bytes .../within/layout-text/style.json | 11 ++-- .../within/paint-circle/expected.png | Bin 594 -> 375 bytes .../within/paint-circle/style.json | 8 +-- .../within/paint-icon/expected.png | Bin 835 -> 607 bytes .../render-tests/within/paint-icon/style.json | 8 +-- .../within/paint-text/expected.png | Bin 1700 -> 853 bytes .../render-tests/within/paint-text/style.json | 11 ++-- 10 files changed, 74 insertions(+), 19 deletions(-) create mode 100644 test/integration/expression-tests/within/invalid-geojson/test.json diff --git a/test/ignores.json b/test/ignores.json index 1f2bb302e6e..854bb320213 100644 --- a/test/ignores.json +++ b/test/ignores.json @@ -24,5 +24,6 @@ "render-tests/within/paint-circle" : "skip - TODO: Within Expression needs to be implemented in mapbox-gl-js", "render-tests/within/paint-icon" : "skip - TODO: Within Expression needs to be implemented in mapbox-gl-js", "render-tests/within/paint-text" : "skip - TODO: Within Expression needs to be implemented in mapbox-gl-js", - "expression-tests/within/basic" : "skip - TODO: Within Expression needs to be implemented in mapbox-gl-js" + "expression-tests/within/basic" : "skip - TODO: Within Expression needs to be implemented in mapbox-gl-js", + "expression-tests/within/invalid-geojson" : "skip - TODO: Within Expression needs to be implemented in mapbox-gl-js" } diff --git a/test/integration/expression-tests/within/invalid-geojson/test.json b/test/integration/expression-tests/within/invalid-geojson/test.json new file mode 100644 index 00000000000..541e8a92e35 --- /dev/null +++ b/test/integration/expression-tests/within/invalid-geojson/test.json @@ -0,0 +1,52 @@ +{ + "expression": ["within", { + "type": "LineString", + "coordinates": [[0, 0], [0, 5], [5, 5], [5, 0]] + }], + "inputs": [[{ + "zoom": 3, + "canonicalID": { + "z": 3, + "x": 3, + "y": 3 + } + }, { + "geometry": { + "type": "Point", + "coordinates": [6, 6] + } + }], [{ + "zoom": 3, + "canonicalID": { + "z": 3, + "x": 3, + "y": 3 + } + }, { + "geometry": { + "type": "Point", + "coordinates": [2, 2] + } + }], [{ + "zoom": 3, + "canonicalID": { + "z": 3, + "x": 3, + "y": 3 + } + }, { + "geometry": { + "type": "LineString", + "coordinates": [[3, 3], [4, 1]] + } + }]], + "expected": { + "compiled": { + "errors": [{ + "key": "", + "error": "'Within' expression requires valid geojson source that contains polygon geometry type." + }], + "result": "error" + } + } +} diff --git a/test/integration/render-tests/within/layout-text/expected.png b/test/integration/render-tests/within/layout-text/expected.png index 0941aa4a1b069fe707b25c10ef5aaa23a4c1bb87..3d0bb4aa1cbf80e8ebfd817e8880754b0eb21de0 100644 GIT binary patch literal 628 zcmV-)0*n2LP)f<0uH+0aI`m&ch*ievj{*gPjhIcz7U0J^TT0!wTJkQTW1a0=xmw>b;eET>``K zwO*gGo#Vg3@OSl>Kc08i1eakg{0Lk0yj3^lDx8L2;Val^FF}D|_s+pSJ-a_y>-_o3?Wl3_|$eE!~K+ zyz^3hB(A|~7|?T5T+oDvr|nHn2qA94vqZumBdo0$2bGU;!+E1?)0xG#ZzNhVQbm(d*6vdV1c7-@lYCAf4`$Oy+U+ zHJN-WTU(FZRX|(Y2Wf7e7oRUJH8tx}SGOXot5Nq95DLwT*PD@4>WNHE4N7_Wro>_| z-Bmy!@GX08e)+1Z-!d>Tc7Q*%QM%Z+EKciH~w?g+R)uc zA6L5_d)ZsB(DJ2yo8_FXay;ql^0#!~`h5LEsr>bQm!xd><)_TK_apXJYVOvs*e^F? z-tM`!{%ZF1*2nX%9#idGefe63_o3(I*}u2$-@g~!Rd-EkO`QN5|Sp44nZC|3? z`fK+t>t*WR@_ndN5;J>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circle/style.json index 5de2bdd2bd4..415c8db9f3c 100644 --- a/test/integration/render-tests/within/paint-circle/style.json +++ b/test/integration/render-tests/within/paint-circle/style.json @@ -2,12 +2,12 @@ "version": 8, "metadata": { "test": { - "width": 150, - "height": 150 + "width": 64, + "height": 64 } }, - "zoom": 3, - "center": [3, 3], + "zoom": 2, + "center": [3.5, 3.5], "sources": { "points": { "type": "geojson", diff --git a/test/integration/render-tests/within/paint-icon/expected.png b/test/integration/render-tests/within/paint-icon/expected.png index ba7e825690c683f1acc3e7186c64fc266dd147da..1a76043df1e7aa17f27f87211ae93a6a69632bb1 100644 GIT binary patch literal 607 zcmV-l0-*hgP)6}RJP0lg4o+3^4@E>eICQInE{>fF&Ou6+PMM^wMG>S;mj+rStx(WdXosp< zN;?PvrA`^7NG&Lo3~`DOG1y<jLHqkB?O>Z>|IPw5N56@~zJ)z>e6VJ*i9JhPYZ``6Kax z_LMGzE-@t@pId%kd?+?)Pv`*%iX-CW=~G}-?AD%&5JCtcgj^K>0k75G*+zyL6tm(N z58c(?+vYUDlK9v|ziRJo!vGAx01UtY48Q;kP;uZw;VBY{1wNWcNcMu4i*#C)}&%M37n4f>+?*J<+3ADH8E`2T3)|SWe@+{kUu*{)(wA2U0VPE002ovPDHLkV1k#H2yy@b literal 835 zcmeAS@N?(olHy`uVBq!ia0vp^(?FPm4M^HB7CvHNVCM34aSW-L^Y+fg?66Xq_^@Cv&LiA3N|tOU0wBr`0^s!n0OH_yDKzBKsJ+~Yj2o!(Bqq*?gM@bIivwLw;@ z$EMByBPV)wed_t^cA9gA*H8Pq%`4>lX|?S66V63dS?!4`%m1nQ@%*Osr`1lmWzFyN zi~d!7Zs8{J(|pryLw~!#91NiyuDcw$v0?o;+3$Wkzf3=Er~f;n!#w_5$=luUras+p zZrWbEBfldevV9_!2#9I6xN;>hEVQiqp*0)a*Ki)$Mv$uH=7oZSCbl zuV#iF-c|82=FQ#T&N;Wfl$+S^x_PXZKdI)=@})OguF9`%E&cgvx1rg$)B7F&mRpzq zlQTAc-g;FSDE{Qc*3iXKHyfF+Cnr9fvY~3h)D3xeDzwYq?y@yllY9H!(W%;|aw08T zuSIcY=jB(t3_Fxn_TfP} z^Wj^2e?RwHF9*`jy}EMlhZX&Y&(0Q4F8XwsE0A+_+qFYk*IG8${{C+-v^_7jywzfzBW4?nbO>DLWm*Z!2P`h3nS;I89gix9`$C=>R1e!{Z$isD177R3D0KD_T%IS*>A!gvm`{~09i VRGqH7!@3V7=IQF^vd$@?2>@<;h57&h diff --git a/test/integration/render-tests/within/paint-icon/style.json b/test/integration/render-tests/within/paint-icon/style.json index afae9dfb04e..b6721020dbe 100644 --- a/test/integration/render-tests/within/paint-icon/style.json +++ b/test/integration/render-tests/within/paint-icon/style.json @@ -2,12 +2,12 @@ "version": 8, "metadata": { "test": { - "width": 150, - "height": 150 + "width": 64, + "height": 64 } }, - "zoom": 3, - "center": [3, 3], + "zoom": 2, + "center": [3.5, 3.5], "sources": { "points": { "type": "geojson", diff --git a/test/integration/render-tests/within/paint-text/expected.png b/test/integration/render-tests/within/paint-text/expected.png index d9fdd1b9a4c3ace9d588d91350a7b3b3870a608d..d020858a65640e232c973cc048aa99f271122b9e 100644 GIT binary patch literal 853 zcmV-b1FHOqP)LOG(WS2sO4O$ViM9R#3~j8ABnYAr{^wf;W+n7*>*z5sDV}A)1zy zNui8#*33T5;V#UT;>wW_gy5wYPycf~8_Eh&VQ-ty4}S2z?>Xn?JpY|@-i3uR46|@( zHQe+ES7<%606|A#FMI`E@TI!nzJPZiEIK_KX3#-vVFKI-op77FUj-v!4m<|e!_Dvj zT%*SBf;(X*w8KL%S<`YB5AA_NaErPZ#adwtd*7Vd`!;XBv`D^*{yDh6SMcJp5{egT|=WAN!5jcUJ(UwRxSslMI-HfT2e zrQ;XC3Fv_FYX8T;mFl@TDC^)&^(txEo1S}I=FlOr%asov=<(MX)sou3E`?;4|k~R6nJ>{pkx?^VHk#CnEx6g3Je1#NLK3& zYG}BP=Mz*?(jnWUqbD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Lukr$a&O)KJfXLajt-Z;Hx&|7lp;&@h>FU3-S$l%Pf9o2pIwVKyE1^C zu5w#CGgt{83U0=c5vSgQg3;}x_@{*Uq$J|_9})ENo39I8NrM1zK34G@;kYBc*gezP zb1S6%?#J-JId<$stB1BRx~?@bz>&3&J;Ndx$dJi+A!0$YIavB2N6iW>FCUDZpG;uD zuLX_tWc|rM`I>=Z)mk|^-l;NmNhTACR&aPj{6bi1<%i3Z_v^H+5Z0&$W>1z5)zD$r zeAQEF9Wfttn2B17qtv6%NXS?}YOAN`fiUFib;kBXQV~5gn7T(@kvm1Pa98UtbV3`* z{%)?*^(`r~W~&|II8KU88ryp=teNk1kW8NzIx#7ZP7HxytsaxcNMYZ*2i+ZY@%KiA z?D5YFHr3(*xqXz6Z&+N>P7Br^pBQd-9v@!@C108=l|nO8V+E6y7)?d^E)a4VF2g2_ zxAc{nZ+}HJ+WQs-&P+R#ZyQ+a#YOzea!1 zq)00k>d0<{EHlSBuC*bpkVG2G5_w|9!rRu|aHWw`PZMr9Trq}w=)MSUBi)X;qpXN- zG<3{HfIt|@#8JibgM89i6=0;hKpvybDewmUnk^xleJtGEgz=73*uH^JF}SVW)-2wP z8{Gx}m=Y&`r6e>J7Qcuf1uVnWoi*4VLzdd-S*IzPU~E6JNspP`p}EUE~a#!e-yU;Yh> Date: Fri, 7 Feb 2020 14:01:59 +0200 Subject: [PATCH 3/3] Change polygon fill color --- .../filter-with-inlined-geojson/expected.png | Bin 321 -> 377 bytes .../filter-with-inlined-geojson/style.json | 2 +- .../within/layout-text/expected.png | Bin 628 -> 645 bytes .../render-tests/within/layout-text/style.json | 2 +- .../within/paint-circle/expected.png | Bin 375 -> 401 bytes .../render-tests/within/paint-circle/style.json | 2 +- .../render-tests/within/paint-icon/expected.png | Bin 607 -> 623 bytes .../render-tests/within/paint-icon/style.json | 2 +- .../render-tests/within/paint-text/expected.png | Bin 853 -> 853 bytes .../render-tests/within/paint-text/style.json | 2 +- 10 files changed, 5 insertions(+), 5 deletions(-) diff --git a/test/integration/render-tests/within/filter-with-inlined-geojson/expected.png b/test/integration/render-tests/within/filter-with-inlined-geojson/expected.png index 17525dffae02437d8a68b744b23ed600cf9c0fa2..61b6f1796b751b0e52a3e6cd738feb7747c5f455 100644 GIT binary patch delta 350 zcmV-k0ipiE0{H@vB!56jL_t(|obA>-N(4a^h2b9qF*gvzEr|OP+=CiuIkSpYU0 z?Fj-1AV9b{OYK8TRR9DKK!9*@mfDAwssIQefB@m*EVU0UReu2xKmY;4#aU_}TB-sd zfB*u7i?h@|v{Z)$*zX?r2Ja&n-NM5<999_J?{EMw@H&A>-ZQvt9^f3VqVd1ofTN}X z##6?p-oazD086klZG7q%d^Za)4_ki$e86Y30IA(8{xl8X08X0*ScScA=r|gmK8uyc z4+oIC)*;-(b60=-1zgY78=pG-pWp&)ufT4Fu~GdMMgRc>2p4CmeQ2o)fB*sr5H8MA w`_NJq009ILAY7cK_MxRJ00IagK)ASF^RdknvA7oNE5njPy5&D`Sie_0kR-eL)~1vfZQ&d`*gx2{^`xaX3KH%?X9{FHBq zdaLj<`25d*LG})-x1O@K%Ql(yimjrwW|rZ^xCV=N`&n0noU3BgoBl4kA?xcBafP!p z?s_+rRWFoQ;As!ii!bi?-|uRDT%2QqV#U3G4}YW;=YIUr#JFkF67@in4K+Jl8}5U` c0t+ZAWA^s9&xxsi;sKKNboFyt=akR{0CLxIeEOr79y?u6Y_cKT@1mUN$>T(UFP}0 zkC}VszHrVn=gw*XA%tIk1KIQdEv7No{e%h!zDPgPahjk#w0|VcncehiNG)z29HNwd zp_gdB-GTx7&};%dLksM^h4y+Iy-a)Ub)M@vHVm7ux8MBsq*^tdrw8eKT4U?Ac2iE$ z5jsU5(+0tB54Ea=r8(&o^?HkZ#cvudd_Y{c2a$ZeI!oNy|mKSO>jre@N}2E&V>*{2qA=6 z4>1S+H0Gb;eET>``KwO*gGo#Vg3@OSl>Kc08i1eakg{0Lk0yj3^l zDx8L2;Val^FF}D|_Uo`RoXyWV>Te$fIVaM=7G*v?Q82v7v?!8JGmKf|P1fBpO! zTrrOce4n=gA@~Q5z?-&n6bwT6;4R&Vvb^(BeI%~IY8cRSQ(Vx5ho|jLP6#1{5JJel z5s_l2wVgQ!hN*{(aN0qC+0LCq3mAqE9CXHZ?i?(D1%I#r7Qg~n01IFNEPw^rz*@ zBCD%W_Y@Ec&5GBXkyPr5Oic|+dHJTqVlUlQKp^lfdv1RDs;b{IFfin<0)oK>7T~G^ z#>SpYI8;0?+uIMNyZfy~BJZ;2=GvSm60xIQz~RUOZ0F9w0$2bGU;!+E1;`wXJLsbA p+<$?A{7!2-Ga-Z!LI@#8kR1tG4)bd~Qhopc002ovPDHLkV1oVZ8b|;D diff --git a/test/integration/render-tests/within/layout-text/style.json b/test/integration/render-tests/within/layout-text/style.json index e07699cadfb..f12044e5fdc 100644 --- a/test/integration/render-tests/within/layout-text/style.json +++ b/test/integration/render-tests/within/layout-text/style.json @@ -73,7 +73,7 @@ "type": "fill", "source": "polygon", "paint": { - "fill-color": "white", + "fill-color": "black", "fill-opacity": 0.5 } }, diff --git a/test/integration/render-tests/within/paint-circle/expected.png b/test/integration/render-tests/within/paint-circle/expected.png index 1c9f07dbefe6cca0810e0080a2d7f54410faab68..2be9f737ca47c032660c18747e71b3664bc6b48f 100644 GIT binary patch delta 374 zcmV-+0g3+i0+9odB!5^*L_t(|ob8!0P6IIzMZc&hski|YG$?nXU9k(@0Rvd zh4{AkvfJ9zb&Pus1gNwp>=<$RFaI?$0oWRzZhY0*fNwSe>;MP74uFV{z!Z3CJ1b}>z!7ks`RUi%34qTC7c0K}s`cM3Uu!GC z!U1r&51b?{zR+fXj50vJ@zY@dFaQHE0D2za+Iw2iQIXAlz(7Gl2qA3}BRsaA107*qoM6N<$f`-4NTL1t6 delta 348 zcmV-i0i*tr1NQ=uB!50hL_t(|ob8!AZo)tmMZpCna>Wiv8>K|-2CVdR+uwU^Ya~yt22dapYBx|qzD;B=sYzSA zl_L&@ALl{4UBSpILqMwCu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YlhH#b>A&j(PO)^+>f05|{+fCJzF zH~259xHD{hXS*@Xv*bzD-THf-`{H+PhR)*-9ppjS>>R$?J-WHkz3! zr|Ibm>g~NwE?1Q-z~i~-yB0c~S7aYCCL?2r9FA%^E~o?R_hIFXt<5%6I4>tA={&)Cn+`c3)R=(35@`Z#@CdYIY@5z zC90}wp_rH-G&*{jva{b)R@NukH$UGh`{(BN$Q2;^hQtaG>U1NNnCK?GewfnJhh+f$ z{nzBmh=}+_$;sn#ONg=F0D|%i_}dB)1?A-Q$$x$BRXi^$dPYe};}jd~kt-u)0}uyW zT-*fZ<-H(_rJD?f57gGyAoqGrO%u+9PPz972CmBMsHmUv9UUEY!5M(~8i-$a?t~i~ z8|7!xY_?H#bu*QfwNq*7W7#H7f6-rz6I-FMuuJw62V_tNux$SbaR3|u2fzVv035)w z4KKhB?*~w))^*PV6G{)XTGz}l48t%C!!RMpZxj&jC~$#ZSO5S307*qoM6N<$f|Naf A2LJ#7 diff --git a/test/integration/render-tests/within/paint-text/style.json b/test/integration/render-tests/within/paint-text/style.json index 7f70b4475d4..8749edb1721 100644 --- a/test/integration/render-tests/within/paint-text/style.json +++ b/test/integration/render-tests/within/paint-text/style.json @@ -73,7 +73,7 @@ "type": "fill", "source": "border", "paint": { - "fill-color": "white", + "fill-color": "black", "fill-opacity": 0.5 } },