Add support for junction=circular (same as junction=roundabout)

(closes #4637)
This commit is contained in:
Bryan Housel
2018-01-02 13:27:11 -05:00
parent a20d26fc9b
commit 9f1b71bb7e
7 changed files with 42 additions and 0 deletions
+3
View File
@@ -2625,6 +2625,9 @@ en:
name: Camp Pitch
# 'terms: tent,rv'
terms: '<translate with synonyms or related terms for ''Camp Pitch'', separated by commas>'
circular:
# junction=circular
name: Traffic Circle
club:
# club=*
name: Club
+14
View File
@@ -52,6 +52,20 @@
"searchable": false,
"name": "Amenity"
},
"circular": {
"geometry": [
"vertex",
"line"
],
"fields": [
"name"
],
"tags": {
"junction": "circular"
},
"name": "Traffic Circle",
"searchable": false
},
"highway": {
"fields": [
"name",
+14
View File
@@ -0,0 +1,14 @@
{
"geometry": [
"vertex",
"line"
],
"fields": [
"name"
],
"tags": {
"junction": "circular"
},
"name": "Traffic Circle",
"searchable": false
}
+4
View File
@@ -21,6 +21,10 @@
{
"key": "amenity"
},
{
"key": "junction",
"value": "circular"
},
{
"key": "highway"
},
+4
View File
@@ -2638,6 +2638,10 @@
"name": "Amenity",
"terms": ""
},
"circular": {
"name": "Traffic Circle",
"terms": ""
},
"highway": {
"name": "Highway",
"terms": ""
+1
View File
@@ -24,6 +24,7 @@ export var osmOneWayTags = {
'motorway_link': true
},
'junction': {
'circular': true,
'roundabout': true
},
'man_made': {
+2
View File
@@ -299,6 +299,7 @@ describe('iD.osmWay', function() {
expect(iD.Way({tags: { highway: 'motorway' }}).isOneWay(), 'motorway').to.be.true;
expect(iD.Way({tags: { highway: 'motorway_link' }}).isOneWay(), 'motorway_link').to.be.true;
expect(iD.Way({tags: { junction: 'roundabout' }}).isOneWay(), 'roundabout').to.be.true;
expect(iD.Way({tags: { junction: 'circular' }}).isOneWay(), 'circular').to.be.true;
});
it('returns false when the way does not have implied oneway tag', function() {
@@ -320,6 +321,7 @@ describe('iD.osmWay', function() {
it('returns false when oneway=no overrides implied oneway tag', function() {
expect(iD.Way({tags: { junction: 'roundabout', oneway: 'no' }}).isOneWay(), 'roundabout').to.be.false;
expect(iD.Way({tags: { junction: 'circular', oneway: 'no' }}).isOneWay(), 'circular').to.be.false;
expect(iD.Way({tags: { highway: 'motorway', oneway: 'no' }}).isOneWay(), 'motorway').to.be.false;
});
});