Autofix indentation issues (eslint --fix)

This commit is contained in:
Marc Jansen
2017-06-19 11:58:00 +02:00
parent a17db4f45c
commit d0ef05977b
196 changed files with 1574 additions and 1574 deletions
+91 -91
View File
@@ -61,97 +61,97 @@ describe('ol.tilegrid.WMTS', function() {
describe('when creating tileGrid from capabilities with and without TileMatrixSetLimits',
function() {
var parser = new ol.format.WMTSCapabilities();
var capabilities;
before(function(done) {
afterLoadText('spec/ol/format/wmts/ign.xml', function(xml) {
try {
capabilities = parser.read(xml);
} catch (e) {
done(e);
}
done();
function() {
var parser = new ol.format.WMTSCapabilities();
var capabilities;
before(function(done) {
afterLoadText('spec/ol/format/wmts/ign.xml', function(xml) {
try {
capabilities = parser.read(xml);
} catch (e) {
done(e);
}
done();
});
});
it('can create tileGrid for EPSG:3857 without matrixLimits',
function() {
var matrixSetObj = capabilities.Contents.TileMatrixSet[0];
var tileGrid;
tileGrid = ol.tilegrid.WMTS.createFromCapabilitiesMatrixSet(
matrixSetObj);
expect(tileGrid.matrixIds_).to.be.an('array');
expect(tileGrid.matrixIds_).to.have.length(22);
expect(tileGrid.matrixIds_).to.eql([
'0', '1', '2', '3', '4', '5', '6', '7', '8', '9', '10', '11',
'12', '13', '14', '15', '16', '17', '18', '19', '20', '21'
]);
expect(tileGrid.resolutions_).to.be.an('array');
expect(tileGrid.resolutions_).to.have.length(22);
expect(tileGrid.resolutions_).to.eql([
156543.033928041, 78271.51696402048, 39135.758482010235,
19567.87924100512, 9783.93962050256, 4891.96981025128,
2445.98490512564, 1222.99245256282, 611.49622628141,
305.7481131407048, 152.8740565703525, 76.43702828517624,
38.21851414258813, 19.10925707129406, 9.554628535647032,
4.777314267823516, 2.388657133911758, 1.194328566955879,
0.5971642834779395, 0.2985821417389697, 0.1492910708694849,
0.0746455354347424
]);
expect(tileGrid.origins_).to.be.an('array');
expect(tileGrid.origins_).to.have.length(22);
expect(tileGrid.origins_).to.eql(
Array.apply(null, Array(22)).map(Array.prototype.valueOf,
[-20037508, 20037508]));
expect(tileGrid.tileSizes_).to.be.an('array');
expect(tileGrid.tileSizes_).to.have.length(22);
expect(tileGrid.tileSizes_).to.eql(
Array.apply(null, Array(22)).map(Number.prototype.valueOf, 256));
});
it('can create tileGrid for EPSG:3857 with matrixLimits',
function() {
var matrixSetObj = capabilities.Contents.TileMatrixSet[0];
var matrixLimitArray = capabilities.Contents.Layer[0]
.TileMatrixSetLink[0].TileMatrixSetLimits;
var tileGrid;
tileGrid = ol.tilegrid.WMTS.createFromCapabilitiesMatrixSet(
matrixSetObj, undefined, matrixLimitArray);
expect(tileGrid.matrixIds_).to.be.an('array');
expect(tileGrid.matrixIds_).to.have.length(20);
expect(tileGrid.matrixIds_).to.eql([
'0', '1', '2', '3', '4', '5', '6', '7', '8', '9', '10', '11',
'12', '13', '14', '15', '16', '17', '18', '19'
]);
expect(tileGrid.resolutions_).to.be.an('array');
expect(tileGrid.resolutions_).to.have.length(20);
expect(tileGrid.resolutions_).to.eql([
156543.033928041, 78271.51696402048, 39135.758482010235,
19567.87924100512, 9783.93962050256, 4891.96981025128,
2445.98490512564, 1222.99245256282, 611.49622628141,
305.7481131407048, 152.8740565703525, 76.43702828517624,
38.21851414258813, 19.10925707129406, 9.554628535647032,
4.777314267823516, 2.388657133911758, 1.194328566955879,
0.5971642834779395, 0.2985821417389697
]);
expect(tileGrid.origins_).to.be.an('array');
expect(tileGrid.origins_).to.have.length(20);
expect(tileGrid.origins_).to.eql(
Array.apply(null, Array(20)).map(Array.prototype.valueOf,
[-20037508, 20037508]));
expect(tileGrid.tileSizes_).to.be.an('array');
expect(tileGrid.tileSizes_).to.have.length(20);
expect(tileGrid.tileSizes_).to.eql(
Array.apply(null, Array(20)).map(Number.prototype.valueOf, 256));
});
});
it('can create tileGrid for EPSG:3857 without matrixLimits',
function() {
var matrixSetObj = capabilities.Contents.TileMatrixSet[0];
var tileGrid;
tileGrid = ol.tilegrid.WMTS.createFromCapabilitiesMatrixSet(
matrixSetObj);
expect(tileGrid.matrixIds_).to.be.an('array');
expect(tileGrid.matrixIds_).to.have.length(22);
expect(tileGrid.matrixIds_).to.eql([
'0', '1', '2', '3', '4', '5', '6', '7', '8', '9', '10', '11',
'12', '13', '14', '15', '16', '17', '18', '19', '20', '21'
]);
expect(tileGrid.resolutions_).to.be.an('array');
expect(tileGrid.resolutions_).to.have.length(22);
expect(tileGrid.resolutions_).to.eql([
156543.033928041, 78271.51696402048, 39135.758482010235,
19567.87924100512, 9783.93962050256, 4891.96981025128,
2445.98490512564, 1222.99245256282, 611.49622628141,
305.7481131407048, 152.8740565703525, 76.43702828517624,
38.21851414258813, 19.10925707129406, 9.554628535647032,
4.777314267823516, 2.388657133911758, 1.194328566955879,
0.5971642834779395, 0.2985821417389697, 0.1492910708694849,
0.0746455354347424
]);
expect(tileGrid.origins_).to.be.an('array');
expect(tileGrid.origins_).to.have.length(22);
expect(tileGrid.origins_).to.eql(
Array.apply(null, Array(22)).map(Array.prototype.valueOf,
[-20037508, 20037508]));
expect(tileGrid.tileSizes_).to.be.an('array');
expect(tileGrid.tileSizes_).to.have.length(22);
expect(tileGrid.tileSizes_).to.eql(
Array.apply(null, Array(22)).map(Number.prototype.valueOf, 256));
});
it('can create tileGrid for EPSG:3857 with matrixLimits',
function() {
var matrixSetObj = capabilities.Contents.TileMatrixSet[0];
var matrixLimitArray = capabilities.Contents.Layer[0]
.TileMatrixSetLink[0].TileMatrixSetLimits;
var tileGrid;
tileGrid = ol.tilegrid.WMTS.createFromCapabilitiesMatrixSet(
matrixSetObj, undefined, matrixLimitArray);
expect(tileGrid.matrixIds_).to.be.an('array');
expect(tileGrid.matrixIds_).to.have.length(20);
expect(tileGrid.matrixIds_).to.eql([
'0', '1', '2', '3', '4', '5', '6', '7', '8', '9', '10', '11',
'12', '13', '14', '15', '16', '17', '18', '19'
]);
expect(tileGrid.resolutions_).to.be.an('array');
expect(tileGrid.resolutions_).to.have.length(20);
expect(tileGrid.resolutions_).to.eql([
156543.033928041, 78271.51696402048, 39135.758482010235,
19567.87924100512, 9783.93962050256, 4891.96981025128,
2445.98490512564, 1222.99245256282, 611.49622628141,
305.7481131407048, 152.8740565703525, 76.43702828517624,
38.21851414258813, 19.10925707129406, 9.554628535647032,
4.777314267823516, 2.388657133911758, 1.194328566955879,
0.5971642834779395, 0.2985821417389697
]);
expect(tileGrid.origins_).to.be.an('array');
expect(tileGrid.origins_).to.have.length(20);
expect(tileGrid.origins_).to.eql(
Array.apply(null, Array(20)).map(Array.prototype.valueOf,
[-20037508, 20037508]));
expect(tileGrid.tileSizes_).to.be.an('array');
expect(tileGrid.tileSizes_).to.have.length(20);
expect(tileGrid.tileSizes_).to.eql(
Array.apply(null, Array(20)).map(Number.prototype.valueOf, 256));
});
});
});