Unit tests are needed for ray-tracing. A functional test suite that proves the code doesn't crash for each surface type is low-hanging fruit. Some "physics" tests, like a parabola has no ray error for an object at infinity and a sphere no ray error for an object at its focus, shoudl be added.
The lower level functions are probably unit test-able, e.g. that the angle between surface normal and entrance ray is the same as surface normal and exit ray.
Unit tests are needed for ray-tracing. A functional test suite that proves the code doesn't crash for each surface type is low-hanging fruit. Some "physics" tests, like a parabola has no ray error for an object at infinity and a sphere no ray error for an object at its focus, shoudl be added.
The lower level functions are probably unit test-able, e.g. that the angle between surface normal and entrance ray is the same as surface normal and exit ray.