title: How to assert certain method is called with Ruby minitest framework?
body: <p>I want to test whether a function invokes other functions properly with minitest Ruby, but I cannot find a proper <code>assert</code> to test from the <a href="http://docs.seattlerb.org/minitest/MiniTest/Assertions.html#method-i-assert_send">doc</a>.</p>
  
  The source code
  
  <pre><code>class SomeClass
    def invoke_function(name)
      name == "right" ? right () : wrong ()
    end
  
    def right
      #...
    end
  
    def wrong
      #...
    end
  end
  </code></pre>
  
  The test code:
  
  <pre><code>describe SomeClass do
    it "should invoke right function" do
      # assert right() is called
    end
  
    it "should invoke other function" do
      # assert wrong() is called
    end
  end
  </code></pre>