- # not even to a logged-in user
- auth_header = bearer_authorization_header
- get api_way_version_path(way_v1.way_id, way_v1.version), :headers => auth_header
- assert_response :forbidden, "Redacted way shouldn't be visible via the version API, even when logged in."
- end
-
- ##
- # check that returned history is the same as getting all
- # versions of a way from the api.
- def test_history_equals_versions
- way = create(:way, :with_history)
- used_way = create(:way, :with_history)
- create(:relation_member, :member => used_way)
- way_with_versions = create(:way, :with_history, :version => 4)
-
- check_history_equals_versions(way.id)
- check_history_equals_versions(used_way.id)
- check_history_equals_versions(way_with_versions.id)
- end
+ assert_response :success, "Redaction shouldn't have stopped history working."
+ assert_dom "osm way[id='#{way.id}'][version='1']", 0,
+ "redacted node #{way.id} version 1 shouldn't be present in the history, even when logged in."