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