I\'m trying to test a controller and I got this error. I understand the error, but don\'t know how to fix it.
test: on CREATE to :user with completely invali
Most straight forward solution to the above problem is to make the request with associated headers. Rails will automatically read this header.
post '/your-custom-route', {}, {'HTTP_REFERER': 'http://www.your-allowed-domain.com'}