*8854* Added tests for getRemoteAddr trust_x_forwarded_for config setting

Forward port of the tests for 8854