Added test for threeWayDiff and started properly decoupling it from the
types used in the js package