X-Git-Url: https://git.openstreetmap.org/rails.git/blobdiff_plain/037585db3933a2954b43bd4b30ea5e30ade00be2..2f9ed9101a6aba23026d37bc6257b1c7afbfdcbe:/test/controllers/old_way_controller_test.rb diff --git a/test/controllers/old_way_controller_test.rb b/test/controllers/old_way_controller_test.rb index 612b4a6a4..e5cb752cd 100644 --- a/test/controllers/old_way_controller_test.rb +++ b/test/controllers/old_way_controller_test.rb @@ -46,6 +46,10 @@ class OldWayControllerTest < ActionController::TestCase ## # check that we can retrieve versions of a way def test_version + propagate_tags(current_ways(:visible_way), ways(:visible_way)) + propagate_tags(current_ways(:used_way), ways(:used_way)) + propagate_tags(current_ways(:way_with_versions), ways(:way_with_versions_v4)) + check_current_version(current_ways(:visible_way).id) check_current_version(current_ways(:used_way).id) check_current_version(current_ways(:way_with_versions).id) @@ -276,4 +280,10 @@ class OldWayControllerTest < ActionController::TestCase # now redact it post :redact, :id => way.way_id, :version => way.version, :redaction => redaction.id end + + def propagate_tags(way, old_way) + way.tags.each do |k, v| + create(:old_way_tag, :old_way => old_way, :k => k, :v => v) + end + end end