All API 0.6 functional tests now pass.

This commit is contained in:
Matt Amos 2008-10-13 15:46:22 +00:00
parent 1e5782f579
commit 3549d8900f
2 changed files with 3 additions and 3 deletions

View file

@ -222,7 +222,7 @@ class Way < ActiveRecord::Base
def create_with_history(user) def create_with_history(user)
check_create_consistency(self, user) check_create_consistency(self, user)
if !self.preconditions_ok? if !self.preconditions_ok?
raise OSM::APIPreconditionsFailedError.new raise OSM::APIPreconditionFailedError.new
end end
self.version = 0 self.version = 0
self.visible = true self.visible = true

View file

@ -140,8 +140,8 @@ class WayControllerTest < Test::Unit::TestCase
"<nd ref='#{nid1}'/></way></osm>" "<nd ref='#{nid1}'/></way></osm>"
put :create put :create
# expect failure # expect failure
assert_response :precondition_failed, assert_response :conflict,
"way upload to closed changeset did not return 'precondition failed'" "way upload to closed changeset did not return 'conflict'"
end end
# ------------------------------------- # -------------------------------------