Add some test to PolygonReplay

This commit is contained in:
GaborFarkas
2016-10-05 18:34:54 +02:00
parent 5cf2e9c072
commit 8e8098b362
6 changed files with 53 additions and 41 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 458 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 780 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 276 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 300 B

View File

@@ -86,11 +86,18 @@ describe('ol.rendering.style.Polygon', function() {
}
it('tests the canvas renderer', function(done) {
map = createMap('canvas');
map = createMap('webgl');
createFeatures();
expectResemble(map, 'spec/ol/style/expected/polygon-types-canvas.png',
IMAGE_TOLERANCE, done);
});
it('tests the webgl renderer', function(done) {
map = createMap('webgl');
createFeatures();
expectResemble(map, 'spec/ol/style/expected/polygon-types-webgl.png',
IMAGE_TOLERANCE, done);
});
});
describe('different types with stroke', function() {
@@ -153,6 +160,14 @@ describe('ol.rendering.style.Polygon', function() {
expectResemble(map, 'spec/ol/style/expected/polygon-types-canvas-stroke.png',
IMAGE_TOLERANCE, done);
});
it('tests the webgl renderer', function(done) {
map = createMap('webgl', 100);
map.getView().setResolution(0.5);
createFeatures();
expectResemble(map, 'spec/ol/style/expected/polygon-types-webgl-stroke.png',
IMAGE_TOLERANCE, done);
});
});
describe('z-index', function() {
@@ -206,6 +221,13 @@ describe('ol.rendering.style.Polygon', function() {
expectResemble(map, 'spec/ol/style/expected/polygon-zindex-canvas.png',
IMAGE_TOLERANCE, done);
});
it('tests the webgl renderer', function(done) {
map = createMap('webgl');
createFeatures();
expectResemble(map, 'spec/ol/style/expected/polygon-zindex-webgl.png',
IMAGE_TOLERANCE, done);
});
});
describe('different fills and strokes', function() {
@@ -259,6 +281,14 @@ describe('ol.rendering.style.Polygon', function() {
map, 'spec/ol/style/expected/polygon-fill-and-strokes-canvas.png',
IMAGE_TOLERANCE, done);
});
it('tests the webgl renderer', function(done) {
map = createMap('webgl');
createFeatures();
expectResemble(
map, 'spec/ol/style/expected/polygon-fill-and-strokes-webgl.png',
5.76, done);
});
});
describe('CanvasPattern and LinearGradient as fills and strokes', function() {