Skip to content

Commit 515de90

Browse files
author
Josh Bernstein
committed
Add unit test for icon tag with no image CesiumGS#5819
1 parent 8898faf commit 515de90

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

Specs/DataSources/KmlDataSourceSpec.js

+12
Original file line numberDiff line numberDiff line change
@@ -263,6 +263,18 @@ defineSuite([
263263
});
264264
});
265265

266+
it('if load contains <icon> tag with no image included, no image is added', function() {
267+
var dataSource = new KmlDataSource(options);
268+
return loadBlob('Data/KML/simpleNoIcon.kml').then(function(blob) {
269+
return dataSource.load(blob);
270+
}).then(function(source) {
271+
expect(source.entities);
272+
expect(source.entities.values.length).toEqual(1);
273+
expect(source.entities._entities._array.length).toEqual(1);
274+
expect(!source.entities._entities._array[0]._billboard._image);
275+
});
276+
});
277+
266278
it('sets DataSource name from Document', function() {
267279
var kml = '<?xml version="1.0" encoding="UTF-8"?>\
268280
<Document>\

0 commit comments

Comments
 (0)