- # in current fixtures ways 1 and 3 all use node 3. ways 2 and 4
- # *used* to use it but doesn't.
- get :ways_for_node, :id => current_nodes(:used_node_1).id
+ node = create(:node)
+ way1 = create(:way)
+ way2 = create(:way)
+ create(:way_node, :way => way1, :node => node)
+ create(:way_node, :way => way2, :node => node)
+ # create an unrelated way
+ create(:way_with_nodes, :nodes_count => 2)
+ # create a way which used to use the node
+ way3_v1 = create(:old_way, :version => 1)
+ _way3_v2 = create(:old_way, :current_way => way3_v1.current_way, :version => 2)
+ create(:old_way_node, :old_way => way3_v1, :node => node)
+
+ get :ways_for_node, :id => node.id