From: Matt Amos Date: Mon, 13 Oct 2008 15:46:22 +0000 (+0000) Subject: All API 0.6 functional tests now pass. X-Git-Tag: live~7573^2~273 X-Git-Url: https://git.openstreetmap.org/rails.git/commitdiff_plain/3549d8900fae286019f9a4ad89d860e4eda76fb6 All API 0.6 functional tests now pass. --- diff --git a/app/models/way.rb b/app/models/way.rb index b2bdfb39b..341bc6e3e 100644 --- a/app/models/way.rb +++ b/app/models/way.rb @@ -222,7 +222,7 @@ class Way < ActiveRecord::Base def create_with_history(user) check_create_consistency(self, user) if !self.preconditions_ok? - raise OSM::APIPreconditionsFailedError.new + raise OSM::APIPreconditionFailedError.new end self.version = 0 self.visible = true diff --git a/test/functional/way_controller_test.rb b/test/functional/way_controller_test.rb index fbc05086f..58bb6a9a1 100644 --- a/test/functional/way_controller_test.rb +++ b/test/functional/way_controller_test.rb @@ -140,8 +140,8 @@ class WayControllerTest < Test::Unit::TestCase "" put :create # expect failure - assert_response :precondition_failed, - "way upload to closed changeset did not return 'precondition failed'" + assert_response :conflict, + "way upload to closed changeset did not return 'conflict'" end # -------------------------------------