simplify scale calculation

update tests to reflect more accurate calculation
This commit is contained in:
mike-000
2020-08-03 22:19:56 +01:00
parent 425214eb4c
commit 95702648b2
4 changed files with 8 additions and 10 deletions

View File

@@ -329,7 +329,7 @@ describe('ol.source.TileWMS', function () {
expect(queryData.get('REQUEST')).to.be('GetLegendGraphic');
expect(queryData.get('SERVICE')).to.be('WMS');
expect(queryData.get('VERSION')).to.be('1.3.0');
expect(queryData.get('SCALE')).to.be('357.14214285714274');
expect(queryData.get('SCALE')).to.be('357.14285714285717');
});
it('does not include SCALE if no resolution was provided', function () {
@@ -365,7 +365,7 @@ describe('ol.source.TileWMS', function () {
expect(queryData.get('REQUEST')).to.be('GetLegendGraphic');
expect(queryData.get('SERVICE')).to.be('WMS');
expect(queryData.get('VERSION')).to.be('1.3.0');
expect(queryData.get('SCALE')).to.be('357.14214285714274');
expect(queryData.get('SCALE')).to.be('357.14285714285717');
expect(queryData.get('STYLE')).to.be('STYLE_VALUE');
expect(queryData.get('FEATURETYPE')).to.be('FEATURETYPE_VALUE');
expect(queryData.get('RULE')).to.be('RULE_VALUE');