| 
    KiCad PCB EDA Suite
    
   | 
 
Test suite for LIB_SYMBOL. More...
#include <qa_utils/wx_utils/unit_test_utils.h>#include <sch_shape.h>#include <sch_pin.h>#include <lib_symbol.h>#include "lib_field_test_utils.h"Go to the source code of this file.
Classes | |
| class | TEST_LIB_SYMBOL_FIXTURE | 
| struct | TEST_LIB_SYMBOL_SUBREF_CASE | 
Functions | |
| BOOST_AUTO_TEST_CASE (DefaultProperties) | |
| Declare the test suite.   | |
| BOOST_AUTO_TEST_CASE (DefaultDrawings) | |
| Check the drawings on a "blank" LIB_SYMBOL.   | |
| BOOST_AUTO_TEST_CASE (DefaultFields) | |
| Check the default fields are present as expected.   | |
| BOOST_AUTO_TEST_CASE (AddedFields) | |
| Test adding fields to a LIB_SYMBOL.   | |
| BOOST_AUTO_TEST_CASE (AddedDrawItems) | |
| Test adding draw items to a LIB_SYMBOL.   | |
| BOOST_AUTO_TEST_CASE (SubReference) | |
| Test the subreference indexing.   | |
| BOOST_AUTO_TEST_CASE (Compare) | |
| Check the compare method.   | |
| BOOST_AUTO_TEST_CASE (GetUnitItems) | |
| Check the fetch unit items code.   | |
| BOOST_AUTO_TEST_CASE (GetUnitDrawItems) | |
| Check the fetch unit draw items code.   | |
| BOOST_AUTO_TEST_CASE (Inheritance) | |
| Check inheritance support.   | |
| BOOST_AUTO_TEST_CASE (CopyConstructor) | |
| Check the copy constructor.   | |
| BOOST_AUTO_TEST_CASE (IsPowerTest) | |
| Check the power and legacy power symbol tests.   | |
Test suite for LIB_SYMBOL.
Definition in file test_lib_part.cpp.
| BOOST_AUTO_TEST_CASE | ( | AddedDrawItems | ) | 
Test adding draw items to a LIB_SYMBOL.
Definition at line 155 of file test_lib_part.cpp.
| BOOST_AUTO_TEST_CASE | ( | AddedFields | ) | 
Test adding fields to a LIB_SYMBOL.
Definition at line 124 of file test_lib_part.cpp.
References KI_TEST::AreDefaultFieldsCorrect(), BOOST_CHECK_PREDICATE(), KI_TEST::FieldNameIdMatches(), and USER.
| BOOST_AUTO_TEST_CASE | ( | Compare | ) | 
Check the compare method.
Definition at line 356 of file test_lib_part.cpp.
References LIB_SYMBOL::AddDrawItem(), ARC, BOOST_CHECK_EQUAL(), LIB_SYMBOL::Compare(), copy, SCH_ITEM::EQUALITY, LIB_SYMBOL::GetDrawItems(), LIB_SYMBOL::GetLibId(), SYMBOL::GetPinNameOffset(), LAYER_DEVICE, LIB_SYMBOL::LockUnits(), RECTANGLE, LIB_SYMBOL::RemoveDrawItem(), SCH_PIN_T, SCH_SHAPE_T, LIB_SYMBOL::SetDescription(), SYMBOL::SetExcludedFromBoard(), SYMBOL::SetExcludedFromBOM(), LIB_SYMBOL::SetFPFilters(), LIB_SYMBOL::SetGlobalPower(), LIB_SYMBOL::SetKeyWords(), LIB_SYMBOL::SetLibId(), LIB_ID::SetLibItemName(), LIB_SYMBOL::SetName(), LIB_SYMBOL::SetNormal(), SYMBOL::SetPinNameOffset(), SYMBOL::SetShowPinNames(), SYMBOL::SetShowPinNumbers(), and LIB_SYMBOL::SetUnitCount().
| BOOST_AUTO_TEST_CASE | ( | CopyConstructor | ) | 
| BOOST_AUTO_TEST_CASE | ( | DefaultDrawings | ) | 
Check the drawings on a "blank" LIB_SYMBOL.
Definition at line 85 of file test_lib_part.cpp.
References BOOST_CHECK_EQUAL().
| BOOST_AUTO_TEST_CASE | ( | DefaultFields | ) | 
Check the default fields are present as expected.
Definition at line 96 of file test_lib_part.cpp.
References KI_TEST::AreDefaultFieldsCorrect(), BOOST_CHECK_EQUAL(), BOOST_CHECK_PREDICATE(), DATASHEET, DESCRIPTION, KI_TEST::FieldNameIdMatches(), FOOTPRINT, REFERENCE, and VALUE.
| BOOST_AUTO_TEST_CASE | ( | DefaultProperties | ) | 
Declare the test suite.
Check that we can get the basic properties out as expected
Definition at line 60 of file test_lib_part.cpp.
References BOOST_AUTO_TEST_CASE(), and BOOST_CHECK_EQUAL().
| BOOST_AUTO_TEST_CASE | ( | GetUnitDrawItems | ) | 
Check the fetch unit draw items code.
Definition at line 558 of file test_lib_part.cpp.
References SCH_PIN::SetNumber().
| BOOST_AUTO_TEST_CASE | ( | GetUnitItems | ) | 
Check the fetch unit items code.
Definition at line 516 of file test_lib_part.cpp.
References SCH_ITEM::SetBodyStyle(), SCH_PIN::SetNumber(), and SCH_ITEM::SetUnit().
| BOOST_AUTO_TEST_CASE | ( | Inheritance | ) | 
Check inheritance support.
Definition at line 578 of file test_lib_part.cpp.
References BOOST_CHECK_EQUAL(), DATASHEET, EDA_ITEM::SetParent(), SCH_FIELD::SetText(), and USER.
| BOOST_AUTO_TEST_CASE | ( | IsPowerTest | ) | 
Check the power and legacy power symbol tests.
Definition at line 668 of file test_lib_part.cpp.
References pin, and PT_POWER_IN.
| BOOST_AUTO_TEST_CASE | ( | SubReference | ) | 
Test the subreference indexing.
Definition at line 171 of file test_lib_part.cpp.
References BOOST_CHECK_EQUAL(), BOOST_TEST_CONTEXT(), and LIB_SYMBOL::LetterSubReference().