I've made a patch that addresses some of the confusion over "test
mode" in Authorize.Net (and CIM) gateways and also allows for easier
co-existence of multiple gateway credentials (some running against the
test gateway, and some against the production gateway) within the same
app.
What I've done in my patch is to document that setting +:test+ to true
does not cause the transaction to run against the test gateway. It
does not change the behavior, and still allows transactions to be sent
with x_test_request=TRUE when setting :test = true on the gateway
initializer.
Additionally, I have allowed for the possibility of specifying which
gateway endpoint to use (:test or :production) in a place other than
the ActiveMerchant::Billing::Base.gateway_mode accessor. This allows
more flexibility in applications where this is considered a variable
value.
I'm open to any feedback and would love to see this accepted in to the
main project.