56 SCH_SHEET_LIST sheets = m_schematic->BuildSheetListSortedByPageNumbers();
58 SCH_SCREEN* screen = sheets.at( 0 ).LastScreen();
72 BOOST_REQUIRE_MESSAGE( resistor,
"Resistor symbol not found in test schematic" );
75 std::vector<SCH_PIN*> rpins = resistor->
GetPins( &sheets.at( 0 ) );
76 BOOST_REQUIRE_EQUAL( rpins.size(), 2 );
79 std::sort( rpins.begin(), rpins.end(), [](
SCH_PIN* a,
SCH_PIN* b ) {
80 return a->GetLocalPosition().y < b->GetLocalPosition().y;
84 bool validTop =
false;
85 std::vector<wxString>
top = rpins[0]->GetStackedPinNumbers( &validTop );
86 BOOST_CHECK( validTop );
87 std::vector<wxString> expectedTop =
ToVector( {
"1",
"2",
"3",
"4",
"5" } );
88 BOOST_CHECK_EQUAL_COLLECTIONS(
top.begin(),
top.end(), expectedTop.begin(), expectedTop.end() );
91 bool validBot =
false;
92 std::vector<wxString> bot = rpins[1]->GetStackedPinNumbers( &validBot );
93 BOOST_CHECK( validBot );
94 std::vector<wxString> expectedBot =
ToVector( {
"6",
"7",
"9",
"10",
"11" } );
95 BOOST_CHECK_EQUAL_COLLECTIONS( bot.begin(), bot.end(), expectedBot.begin(), expectedBot.end() );
98 size_t total =
top.size() + bot.size();
BOOST_CHECK_EQUAL(result, "25.4")