adding unit test for dom_err.
adding unit test for dom_err.

stan-dev/math,stan-dev/math,stan-dev/math,stan-dev/stan,stan-dev/stan,stan-dev/stan,stan-dev/math,stan-dev/math,stan-dev/math,stan-dev/stan,stan-dev/stan,stan-dev/math,stan-dev/math,stan-dev/math