Skip to content

Commit

Permalink
Merge dfa35b5 into 6eeeb3a
Browse files Browse the repository at this point in the history
  • Loading branch information
ChrisLoer committed Jun 26, 2018
2 parents 6eeeb3a + dfa35b5 commit 3790d92
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/feature.js
@@ -1,7 +1,7 @@

export default function createFeature(id, type, geom, tags) {
var feature = {
id: id || null,
id: typeof id === 'undefined' ? null : id,
type: type,
geometry: geom,
tags: tags,
Expand Down
2 changes: 1 addition & 1 deletion test/fixtures/feature-tiles.json
@@ -1 +1 @@
{"z0-0-0":[{"geometry":[[[3186,2048],[3186,2037],[3197,2037],[3197,2048],[3186,2048]]],"type":3,"tags":{"prop0":"value0","prop1":{"this":"that"}}}]}
{"z0-0-0":[{"geometry":[[[3186,2048],[3186,2037],[3197,2037],[3197,2048],[3186,2048]]],"type":3,"tags":{"prop0":"value0","prop1":{"this":"that"}},"id": 0}]}
3 changes: 2 additions & 1 deletion test/fixtures/feature.json
Expand Up @@ -9,5 +9,6 @@
"properties": {
"prop0": "value0",
"prop1": {"this": "that"}
}
},
"id": 0
}
2 changes: 1 addition & 1 deletion test/test-full.js
Expand Up @@ -22,7 +22,7 @@ function testTiles(inputFile, expectedFile, options) {
test('full tiling test: ' + expectedFile.replace('-tiles.json', ''), function (t) {
var tiles = genTiles(getJSON(inputFile), options);
// fs.writeFileSync(path.join(__dirname, '/fixtures/' + expectedFile), JSON.stringify(tiles));
t.same(getJSON(expectedFile), tiles);
t.same(tiles, getJSON(expectedFile));
t.end();
});
}
Expand Down

0 comments on commit 3790d92

Please sign in to comment.