From b149a69efde75207b2b36cfc651cb9aee16d95bd Mon Sep 17 00:00:00 2001 From: Joachim Schleicher Date: Thu, 19 Oct 2023 21:31:52 +0200 Subject: [PATCH] add test case for path higlight therefore setting opacity of the example path to 0.6 --- umap/static/umap/test/Feature.js | 6 ++++++ umap/static/umap/test/Map.Export.js | 2 ++ umap/static/umap/test/_pre.js | 2 +- 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/umap/static/umap/test/Feature.js b/umap/static/umap/test/Feature.js index 228e2bb1..7ef10051 100644 --- a/umap/static/umap/test/Feature.js +++ b/umap/static/umap/test/Feature.js @@ -238,6 +238,12 @@ describe('L.U.FeatureMixin', function () { happen.click(qs('div.leaflet-marker-icon')) assert.ok(qs('.umap-icon-active')) }) + + it('should highlight path', function () { + happen.click(qs('path[stroke-opacity="0.6"]')) + var path = qs('path[stroke-opacity="1"]') + assert.ok(path) + }) }) describe('#tooltip', function () { diff --git a/umap/static/umap/test/Map.Export.js b/umap/static/umap/test/Map.Export.js index 09ce3588..23028192 100644 --- a/umap/static/umap/test/Map.Export.js +++ b/umap/static/umap/test/Map.Export.js @@ -64,6 +64,7 @@ describe('L.U.Map.Export', function () { properties: { _umap_options: { fill: false, + opacity: 0.6, }, name: 'test', }, @@ -187,6 +188,7 @@ describe('L.U.Map.Export', function () { properties: { _umap_options: { fill: false, + opacity: 0.6, }, name: 'test', }, diff --git a/umap/static/umap/test/_pre.js b/umap/static/umap/test/_pre.js index dda0c79e..fa3ad7fe 100644 --- a/umap/static/umap/test/_pre.js +++ b/umap/static/umap/test/_pre.js @@ -254,7 +254,7 @@ var RESPONSES = { }, type: 'Feature', id: 20, - properties: { _umap_options: { fill: false }, name: 'test' }, + properties: { _umap_options: { fill: false, opacity: 0.6 }, name: 'test' }, }, { geometry: {