title: Using mocha for controller in functional test with RSPEC
body: <p>I'm doing some tests here using Rspec and I would like to assure that the controller is calling the log method in some actions. I'm also using mocha.</p>
  
  <p>I would like something like this:</p>
  
  <pre><code>it "update action should redirect when model is valid" do
      Tag.any_instance.stubs(:valid?).returns(true)
      put :update, :id =&gt; Tag.first
      controller.expects(:add_team_log).at_least_once
      response.should redirect_to(edit_admin_tag_url(assigns[:tag]))
    end
  </code></pre>
  
  <p>is there something to use as the 'controller' variable? I tried self, the controller class name...</p>