74 BOOST_REQUIRE_MESSAGE( m_board,
"Failed to load board issue24799" );
76 PAD* slotPad =
nullptr;
77 PAD* roundPad =
nullptr;
79 for(
FOOTPRINT* footprint : m_board->Footprints() )
81 for(
PAD*
pad : footprint->Pads() )
86 if(
pad->GetDrillSizeX() !=
pad->GetDrillSizeY() )
93 BOOST_REQUIRE_MESSAGE( slotPad,
"Fixture must contain an oblong NPTH pad" );
94 BOOST_REQUIRE_MESSAGE( roundPad,
"Fixture must contain a round NPTH pad" );
98 BOOST_REQUIRE_EQUAL( m_board->Zones().size(), 1 );
100 const std::shared_ptr<SHAPE_POLY_SET>& fill = m_board->Zones().front()->GetFilledPolysList(
F_Cu );
104 const int searchDist =
pcbIUScale.mmToIU( 2.0 );
108 for(
PAD*
pad : { roundPad, slotPad } )
112 BOOST_REQUIRE_MESSAGE( fill->Collide(
pad->GetEffectiveHoleShape().get(), searchDist, &
actual ),
113 "No fill within 2 mm of the hole, standoff is far too large" );
116 pad->GetDrillSizeX() ==
pad->GetDrillSizeY() ? wxString(
"round" )
117 : wxString(
"oblong" ),
121 BOOST_CHECK_GE(
actual, minGap );
122 BOOST_CHECK_LE(
actual, maxGap );
127 BOOST_REQUIRE_MESSAGE( bds.
m_DRCEngine,
"DRC engine not initialized" );
135 int edgeClearanceCount = 0;
136 int holeClearanceCount = 0;
139 [&](
const std::shared_ptr<DRC_ITEM>& aItem,
const VECTOR2I& ,
int ,
143 ++edgeClearanceCount;
145 ++holeClearanceCount;
152 BOOST_TEST_MESSAGE( wxString::Format(
"Edge clearance violations: %d, hole clearance: %d", edgeClearanceCount,
153 holeClearanceCount ) );
BOOST_CHECK_EQUAL(result, "25.4")