Intercept method calls in RSpec tests