diff --git a/test/index.html b/test/index.html index 1e5975595..7f5d2a878 100644 --- a/test/index.html +++ b/test/index.html @@ -91,7 +91,6 @@ - diff --git a/test/spec/actions/deprecate_tags.js b/test/spec/actions/deprecate_tags.js deleted file mode 100644 index 61d1da4fb..000000000 --- a/test/spec/actions/deprecate_tags.js +++ /dev/null @@ -1,47 +0,0 @@ -describe('iD.actions.DeprecateTags', function () { - it('deprecates tags', function () { - var entity = iD.Entity({ tags: { barrier: 'wire_fence' } }), - graph = iD.actions.DeprecateTags(entity.id)(iD.Graph([entity])), - undeprecated = { - barrier: 'fence', - fence_type: 'chain' - }; - expect(graph.entity(entity.id).tags).to.eql(undeprecated); - }); - - it('does not overwrite explicit tags', function () { - var entity = iD.Entity({ tags: { barrier: 'wire_fence', fence_type: 'foo' } }), - graph = iD.actions.DeprecateTags(entity.id)(iD.Graph([entity])), - undeprecated = { - barrier: 'fence', - fence_type: 'foo' - }; - expect(graph.entity(entity.id).tags).to.eql(undeprecated); - }); - - it('leaves other tags alone', function () { - var entity = iD.Entity({ tags: { highway: 'ford', name: 'Foo' } }), - graph = iD.actions.DeprecateTags(entity.id)(iD.Graph([entity])), - undeprecated = { - ford: 'yes', - name: 'Foo' - }; - expect(graph.entity(entity.id).tags).to.eql(undeprecated); - }); - - it('wipes out tags that should be entirely removed', function () { - var entity = iD.Entity({ tags: { 'tiger:source': 'foo' } }), - graph = iD.actions.DeprecateTags(entity.id)(iD.Graph([entity])), - undeprecated = { }; - expect(graph.entity(entity.id).tags).to.eql(undeprecated); - }); - - it('replaces keys', function () { - var entity = iD.Entity({ tags: { power_rating: '1 billion volts' } }), - graph = iD.actions.DeprecateTags(entity.id)(iD.Graph([entity])), - undeprecated = { - 'generator:output': '1 billion volts' - }; - expect(graph.entity(entity.id).tags).to.eql(undeprecated); - }); -});