49 m_mgr.LoadProject(
"" );
82 m_screen->Append( busWire );
86 m_screen->Append( label );
89 SCH_SHEET_LIST sheets = m_schematic->BuildSheetListSortedByPageNumbers();
90 m_schematic->ConnectionGraph()->Recalculate( sheets,
true );
98 BOOST_CHECK( busConn->
IsBus() );
99 BOOST_CHECK( busConn->
Members().empty() );
102 label->
SetText( wxT(
"test[0..7]" ) );
108 m_schematic->ConnectionGraph()->Recalculate( sheets,
false );
113 BOOST_CHECK( busConn->
IsBus() );
115 "Bus wire should have members after label changed to bus name" );
118 if( !busConn->
Members().empty() )
134 m_screen->Append( busWire );
138 m_screen->Append( label );
141 SCH_SHEET_LIST sheets = m_schematic->BuildSheetListSortedByPageNumbers();
142 m_schematic->ConnectionGraph()->Recalculate( sheets,
true );
149 BOOST_CHECK( busConn->
IsBus() );
151 "Bus wire should have members from bus label" );
154 if( !busConn->
Members().empty() )
virtual void SetText(const wxString &aText)
Each graphical item can have a SCH_CONNECTION describing its logical connection (to a bus or net).
const std::vector< std::shared_ptr< SCH_CONNECTION > > & Members() const
void SetConnectivityDirty(bool aDirty=true)
SCH_CONNECTION * Connection(const SCH_SHEET_PATH *aSheet=nullptr) const
Retrieve the connection associated with this object in the given sheet.
Segment description base class to describe items which have 2 end points (track, wire,...
void SetEndPoint(const VECTOR2I &aPosition)
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...
Sheet symbol placed in a schematic, and is the entry point for a sub schematic.
std::unique_ptr< SCHEMATIC > m_schematic
LABEL_BUS_CONNECTIVITY_FIXTURE()
BOOST_AUTO_TEST_SUITE(CadstarPartParser)
BOOST_REQUIRE(intersection.has_value()==c.ExpectedIntersection.has_value())
BOOST_AUTO_TEST_SUITE_END()
BOOST_FIXTURE_TEST_CASE(LabelNetToBusConnectivity, LABEL_BUS_CONNECTIVITY_FIXTURE)
Test that changing a label from a net name to a bus name properly updates the connected bus wire's co...
BOOST_CHECK_MESSAGE(totalMismatches==0, std::to_string(totalMismatches)+" board(s) with strategy disagreements")
BOOST_CHECK_EQUAL(result, "25.4")
VECTOR2< int32_t > VECTOR2I