48 for(
unsigned i = 0; i < 4; ++i )
52 std::ostringstream ss;
89 BOOST_CHECK_THROW( m_empty_path.at( 0 ), std::out_of_range );
130 BOOST_CHECK( m_empty_path == otherEmpty );
132 BOOST_CHECK( m_empty_path != m_linear );
140 std::unique_ptr<SCHEMATIC> schematic;
141 wxFileName fn( wxString::Format( wxS(
"%snetlists/complex_hierarchy" ),
154 BOOST_CHECK( hierarchy.
GetOrdinalPath( schematic->RootScreen() ).value() == hierarchy.at( 0 ) );
157 SCH_SHEET* sheet = hierarchy.at( 1 ).Last();
161 sheet = hierarchy.at( 2 ).Last();
static SCHEMATIC * LoadSchematic(const wxString &aFileName, bool aSetActive, bool aForceDefaultProject, PROJECT *aProject=nullptr)
A container for handling SCH_SHEET_PATH objects in a flattened hierarchy.
std::optional< SCH_SHEET_PATH > GetOrdinalPath(const SCH_SCREEN *aScreen) const
Return the ordinal sheet path of aScreen.
Handle access to a stack of flattened SCH_SHEET objects by way of a path for creating a flattened sch...
void push_back(SCH_SHEET *aSheet)
Forwarded method from std::vector.
Sheet symbol placed in a schematic, and is the entry point for a sub schematic.
SCH_SCREEN * GetScreen() const
std::vector< SCH_SHEET > m_sheets
handy store of SCH_SHEET objects
SCH_SHEET_PATH m_empty_path
SCH_SHEET_PATH m_linear
We look at sheet 2 in the hierarchy: Sheets: 0 -> 1 -> 2.
TEST_SCH_SHEET_PATH_FIXTURE()
static const std::string ProjectFileExtension
std::string GetEeschemaTestDataDir()
Get the configured location of Eeschema test data.
bool IsUUIDPathWithLevels(const std::string &aStr, unsigned aLevels)
Predicate to check a string is a UUID path format.
Definition of the SCH_SHEET_PATH and SCH_SHEET_LIST classes for Eeschema.
BOOST_CHECK_EQUAL(ret, c.m_exp_result)
BOOST_AUTO_TEST_SUITE_END()
BOOST_AUTO_TEST_CASE(Empty)
Declare the test suite.
BOOST_CHECK_PREDICATE(ArePolylineEndPointsNearCircle,(chain)(c.m_geom.m_center_point)(radius)(accuracy+epsilon))
Test utilities for timestamps.
VECTOR2< int32_t > VECTOR2I
Definition of file extensions used in Kicad.