49 "Issue 13626: clockwise semicircle",
50 {-428880000, 117229160 },
51 {-430060565, 113472820 },
53 {-431241130, 109716480 },
57 "Issue 13626: anticlockwise arc",
58 { -431241130, 109716480 },
59 { -434923630, 112954230 },
61 { -439827050, 112936200 },
71 BOOST_TEST_INFO_SCOPE( c.m_CaseName );
108 "Issue 15694: clockwise arc",
119 "Issue 15694: anticlockwise arc",
133 const double angle_tol = 0.1;
137 BOOST_TEST_INFO_SCOPE( c.m_CaseName );
167 ( angle.
AsDegrees() )( c.m_ExpectedAngleAfterSwapDeg )( 360.0 )( angle_tol ) );
EDA_SHAPE_MOCK(SHAPE_T aShapeType)
EDA_ANGLE GetArcAngle() const
void SetCenter(const VECTOR2I &aCenter)
VECTOR2I getCenter() const
EDA_SHAPE(SHAPE_T aType, int aLineWidth, FILL_T aFill)
const VECTOR2I & GetEnd() const
Return the ending point of the graphic.
void SetStart(const VECTOR2I &aStart)
const VECTOR2I & GetStart() const
Return the starting point of the graphic.
bool EndsSwapped() const
Have the start and end points been swapped since they were set?
void SetArcGeometry(const VECTOR2I &aStart, const VECTOR2I &aMid, const VECTOR2I &aEnd)
Set the three controlling points for an arc.
void SetArcAngleAndEnd(const EDA_ANGLE &aAngle, bool aCheckNegativeAngle=false)
Set the end point from the angle center and start.
static int DefaultAccuracyForPCB()
bool IsWithinWrapped(T aValue, T aNominal, T aWrap, T aError)
Check if a value is within a tolerance of a nominal value, wrapping to a given val.
bool IsWithin(T aValue, T aNominal, T aError)
Check if a value is within a tolerance of a nominal value.
bool IsVecWithinTol(const VEC &aVec, const VEC &aExp, typename VEC::coord_type aTol)
Check that both x and y of a vector are within expected error.
bool m_ExpectedStartEndSwapped
VECTOR2I m_ExpectedEndBeforeSwap
bool m_ExpectedStartEndSwapped
VECTOR2I m_ExpectedCenter
double m_ExpectedAngleAfterSwapDeg
VECTOR2I m_ExpectedEndAfterSwap
BOOST_AUTO_TEST_SUITE(CadstarPartParser)
static const std::vector< SET_ARC_GEOMETRY_CASE > set_arc_geometry_cases
BOOST_AUTO_TEST_CASE(SetAngleAndEnd)
static const std::vector< SET_ANGLE_END_CASE > set_angle_end_cases
BOOST_AUTO_TEST_SUITE_END()
BOOST_CHECK_PREDICATE(ArePolylineEndPointsNearCircle,(chain)(c.m_geom.m_center_point)(radius)(accuracy+epsilon))
BOOST_CHECK_EQUAL(result, "25.4")
VECTOR2< int32_t > VECTOR2I