mirror of
https://github.com/FoggedLens/iD.git
synced 2026-02-13 17:23:02 +00:00
- iD.Context -> iD.coreContext - iD.Graph -> iD.coreGraph - iD.Node -> iD.osmNode - iD.Way -> iD.osmWay - iD.Relation -> iD.osmRelation
10 lines
473 B
JavaScript
10 lines
473 B
JavaScript
describe('iD.actionChangeMember', function () {
|
|
it('updates the member at the specified index', function () {
|
|
var node = iD.osmNode(),
|
|
relation = iD.osmRelation({members: [{id: node.id}]}),
|
|
action = iD.actionChangeMember(relation.id, {id: node.id, role: 'node'}, 0),
|
|
graph = action(iD.coreGraph([node, relation]));
|
|
expect(graph.entity(relation.id).members).to.eql([{id: node.id, role: 'node'}]);
|
|
});
|
|
});
|