Possible bug in Rails 4 Tutorial, section 9.6, exercise 1
问题 I'm working through the Rails 4 version of Michael Hartl's Rails Tutorial and having trouble with section 9.6 exercise 1 (Listing 9.49). It looks like the test in the tutorial passes for the wrong reason. Before the PATCH request, user.admin? is false by default; after the PATCH request user.admin? is still false (thus passing the test) because the PATCH request is not getting to the UsersController#update method. Here's my code: spec/requests/user_pages_spec.rb (other tests removed to