Fix write out GeoJSON features with id equal to 0

This commit is contained in:
Frederic Junod committed 2015-10-28 15:09:31 +01:00
1 parent 4846a49258
commit d59f6979f7
2 files changed
+7 -1

No files matched your search

@@ -551,6 +551,12 @@ describe('ol.format.GeoJSON', function() {
expect(geojson.geometry).to.eql(null);
});
it('writes out a feature with id equal to 0 correctly', function() {
var feature = new ol.Feature();
feature.setId(0);
var geojson = format.writeFeatureObject(feature);
expect(geojson.id).to.eql(0);
});
});
describe('#writeGeometry', function() {