Transformed

This commit is contained in:
Tim Schaub
2017-12-11 16:29:33 -07:00
parent 1cdb6a66f0
commit 7f47883c48
737 changed files with 22216 additions and 21609 deletions

View File

@@ -1,15 +1,13 @@
goog.require('ol.proj');
goog.require('ol.source.UrlTile');
goog.require('ol.tilegrid');
import _ol_proj_ from '../../../../src/ol/proj.js';
import _ol_source_UrlTile_ from '../../../../src/ol/source/UrlTile.js';
import _ol_tilegrid_ from '../../../../src/ol/tilegrid.js';
describe('ol.source.UrlTile', function() {
describe('#setUrl()', function() {
it('sets the URL for the source', function() {
var source = new ol.source.UrlTile({});
var source = new _ol_source_UrlTile_({});
var url = 'https://example.com/';
source.setUrl(url);
@@ -18,7 +16,7 @@ describe('ol.source.UrlTile', function() {
});
it('updates the key for the source', function() {
var source = new ol.source.UrlTile({});
var source = new _ol_source_UrlTile_({});
var url = 'https://example.com/';
source.setUrl(url);
@@ -29,7 +27,7 @@ describe('ol.source.UrlTile', function() {
describe('#setUrls()', function() {
it('sets the URL for the source', function() {
var source = new ol.source.UrlTile({});
var source = new _ol_source_UrlTile_({});
var urls = [
'https://a.example.com/',
@@ -42,7 +40,7 @@ describe('ol.source.UrlTile', function() {
});
it('updates the key for the source', function() {
var source = new ol.source.UrlTile({});
var source = new _ol_source_UrlTile_({});
var urls = [
'https://a.example.com/',
@@ -57,7 +55,7 @@ describe('ol.source.UrlTile', function() {
describe('url option', function() {
it('expands url template', function() {
var tileSource = new ol.source.UrlTile({
var tileSource = new _ol_source_UrlTile_({
url: '{1-3}'
});
@@ -71,9 +69,9 @@ describe('ol.source.UrlTile', function() {
var tileSource, tileGrid;
beforeEach(function() {
tileSource = new ol.source.UrlTile({
tileSource = new _ol_source_UrlTile_({
projection: 'EPSG:3857',
tileGrid: ol.tilegrid.createXYZ({maxZoom: 6}),
tileGrid: _ol_tilegrid_.createXYZ({maxZoom: 6}),
url: '{z}/{x}/{y}',
wrapX: true
});
@@ -169,8 +167,8 @@ describe('ol.source.UrlTile', function() {
beforeEach(function() {
sourceOptions = {
tileGrid: ol.tilegrid.createXYZ({
extent: ol.proj.get('EPSG:4326').getExtent()
tileGrid: _ol_tilegrid_.createXYZ({
extent: _ol_proj_.get('EPSG:4326').getExtent()
})
};
});
@@ -178,7 +176,7 @@ describe('ol.source.UrlTile', function() {
describe('using a "url" option', function() {
beforeEach(function() {
sourceOptions.url = url;
source = new ol.source.UrlTile(sourceOptions);
source = new _ol_source_UrlTile_(sourceOptions);
});
it('returns the XYZ URL', function() {
@@ -191,7 +189,7 @@ describe('ol.source.UrlTile', function() {
describe('using a "urls" option', function() {
beforeEach(function() {
sourceOptions.urls = ['some_xyz_url1', 'some_xyz_url2'];
source = new ol.source.UrlTile(sourceOptions);
source = new _ol_source_UrlTile_(sourceOptions);
});
it('returns the XYZ URLs', function() {
@@ -206,7 +204,7 @@ describe('ol.source.UrlTile', function() {
sourceOptions.tileUrlFunction = function() {
return 'some_xyz_url';
};
source = new ol.source.UrlTile(sourceOptions);
source = new _ol_source_UrlTile_(sourceOptions);
});
it('returns null', function() {