73 SCH_SHEET_LIST sheets = m_schematic->BuildSheetListSortedByPageNumbers();
77 std::map<wxString, wxString> pinNetNames;
92 wxString pinKey = ref +
"." +
pin->GetNumber();
93 pinNetNames[pinKey] = conn->
Name();
102 const std::vector<wxString> expectedNets = {
"CON_B_7",
"CON_B_8",
"CON_B_1",
"CON_B_2",
103 "CON_B_3",
"CON_B_4",
"CON_B_5",
"CON_B_6" };
105 for(
int i = 0; i < 8; i++ )
107 wxString ref = wxString::Format(
"R%d.1", i + 9 );
108 BOOST_REQUIRE_MESSAGE( pinNetNames.count( ref ), wxString::Format(
"%s should have a net assigned", ref ) );
110 wxString netName = pinNetNames[ref];
112 wxString::Format(
"%s expected %s, got %s", ref, expectedNets[i], netName ) );
Calculate the connectivity of a schematic and generates netlists.
Instantiate the current locale within a scope in which you are expecting exceptions to be thrown.
Each graphical item can have a SCH_CONNECTION describing its logical connection (to a bus or net).
wxString Name(bool aIgnoreSheet=false) const
Base class for any item which can be embedded within the SCHEMATIC container class,...
A container for handling SCH_SHEET_PATH objects in a flattened hierarchy.
Handle access to a stack of flattened SCH_SHEET objects by way of a path for creating a flattened sch...
std::vector< const SCH_PIN * > GetPins(const SCH_SHEET_PATH *aSheet) const
Retrieve a list of the SCH_PINs for the given sheet path.
const wxString GetRef(const SCH_SHEET_PATH *aSheet, bool aIncludeUnit=false) const override
void LoadSchematic(SETTINGS_MANAGER &aSettingsManager, const wxString &aRelPath, std::unique_ptr< SCHEMATIC > &aSchematic)
std::vector< FAB_LAYER_COLOR > dummy
std::unique_ptr< SCHEMATIC > m_schematic
SETTINGS_MANAGER m_settingsManager
BOOST_FIXTURE_TEST_CASE(Issue23840BusGroupToVector, ISSUE23840_FIXTURE)
BOOST_CHECK_MESSAGE(totalMismatches==0, std::to_string(totalMismatches)+" board(s) with strategy disagreements")