Curve test code