|
KiCad PCB EDA Suite
|
#include <boost/test/unit_test.hpp>#include <tool/tool_manager.h>#include <pcbnew_utils/board_test_utils.h>#include <board.h>#include <board_commit.h>#include <connectivity/connectivity_data.h>#include <netinfo.h>#include <footprint.h>#include <pad.h>#include <pcb_shape.h>#include <pcb_text.h>#include <pcb_group.h>#include <pcb_board_outline.h>#include <lset.h>#include <generators/pcb_via_stack.h>#include <pcb_view.h>#include <tools/pcb_selection_tool.h>Go to the source code of this file.
Functions | |
| BOOST_AUTO_TEST_CASE (RecursesThroughGroups) | |
| BOOST_AUTO_TEST_CASE (RemovedFootprintChildLeavesConnectivity) | |
| BOOST_AUTO_TEST_CASE (MakeImageCreatesTransientCopy) | |
| BOOST_AUTO_TEST_CASE (ReturnsBoardFromManager) | |
| BOOST_AUTO_TEST_CASE (RemoveFootprintTextFromBoardEditor) | |
| BOOST_AUTO_TEST_CASE (ReusedCommitModifyAfterAdd) | |
| BOOST_AUTO_TEST_CASE (RemoveFootprintPrunesSelectedChildren) | |
| BOOST_AUTO_TEST_CASE (LayerChangeOffEdgeCutsUpdatesBoardOutline) | |
| BOOST_AUTO_TEST_CASE (RevertAfterDraggingAViaStackRestoresItsHops) | |
| BOOST_AUTO_TEST_CASE (RegeneratingAViaStackDoesNotDoubleStageItsHops) | |
| BOOST_AUTO_TEST_CASE (UpdateOutsideAnEditIsInert) | |
| BOOST_AUTO_TEST_CASE | ( | LayerChangeOffEdgeCutsUpdatesBoardOutline | ) |
Definition at line 205 of file test_board_commit.cpp.
References BOARD::Add(), BOARD::BoardOutline(), BOOST_CHECK_EQUAL(), Cmts_User, Edge_Cuts, PCB_BOARD_OUTLINE::GetOutline(), COMMIT::Modify(), SHAPE_POLY_SET::OutlineCount(), BOARD_COMMIT::Push(), RECTANGLE, PCB_SHAPE::SetEnd(), TOOL_MANAGER::SetEnvironment(), PCB_SHAPE::SetLayer(), PCB_SHAPE::SetStart(), SKIP_UNDO, and BOARD::UpdateBoardOutline().
| BOOST_AUTO_TEST_CASE | ( | MakeImageCreatesTransientCopy | ) |
Definition at line 95 of file test_board_commit.cpp.
References BOOST_REQUIRE(), copy, BOARD_COMMIT::MakeImage(), SEGMENT, and UR_TRANSIENT.
| BOOST_AUTO_TEST_CASE | ( | RecursesThroughGroups | ) |
Definition at line 40 of file test_board_commit.cpp.
References BOOST_AUTO_TEST_CASE(), BOOST_CHECK_EQUAL(), CHT_MODIFY, COMMIT::GetStatus(), group, RECURSE, TOOL_MANAGER::RegisterTool(), SEGMENT, TOOL_MANAGER::SetEnvironment(), and BOARD_COMMIT::Stage().
| BOOST_AUTO_TEST_CASE | ( | RegeneratingAViaStackDoesNotDoubleStageItsHops | ) |
Definition at line 288 of file test_board_commit.cpp.
References BOARD::Add(), LSET::AllCuMask(), LSET::AllTechMask(), CHT_REMOVE, PCB_VIA_STACK::EditFinish(), PCB_VIA_STACK::EditStart(), F_Cu, PCB_GROUP::GetBoardItems(), COMMIT::GetStatus(), In2_Cu, In3_Cu, PCB_VIA_STACK::Regenerate(), TOOL_MANAGER::RegisterTool(), BOARD_COMMIT::Revert(), BOARD::SetCopperLayerCount(), BOARD::SetEnabledLayers(), PCB_VIA_STACK::SetEndLayer(), TOOL_MANAGER::SetEnvironment(), PCB_GENERATOR::SetPosition(), PCB_VIA_STACK::SetStartLayer(), PCB_VIA_STACK::SetViaDrill(), PCB_VIA_STACK::SetViaSize(), and PCB_VIA_STACK::Update().
| BOOST_AUTO_TEST_CASE | ( | RemovedFootprintChildLeavesConnectivity | ) |
Definition at line 62 of file test_board_commit.cpp.
References BOARD::Add(), FOOTPRINT::Add(), BOOST_CHECK_EQUAL(), BOARD::BuildConnectivity(), FOOTPRINT, BOARD::GetConnectivity(), CONNECTIVITY_DATA::GetNetItems(), PAD, pad, PCB_PAD_T, BOARD_COMMIT::Push(), TOOL_MANAGER::RegisterTool(), COMMIT::Remove(), and TOOL_MANAGER::SetEnvironment().
| BOOST_AUTO_TEST_CASE | ( | RemoveFootprintPrunesSelectedChildren | ) |
Definition at line 174 of file test_board_commit.cpp.
References BOARD::Add(), FOOTPRINT::Add(), SELECTION_TOOL::AddItemToSel(), BOOST_REQUIRE(), SELECTION::Contains(), FOOTPRINT, PCB_SELECTION_TOOL::GetSelection(), EDA_ITEM::IsSelected(), PAD, pad, BOARD_COMMIT::Push(), TOOL_MANAGER::RegisterTool(), COMMIT::Remove(), TOOL_MANAGER::SetEnvironment(), SKIP_TEARDROPS, and SKIP_UNDO.
| BOOST_AUTO_TEST_CASE | ( | RemoveFootprintTextFromBoardEditor | ) |
Definition at line 120 of file test_board_commit.cpp.
References BOARD::Add(), FOOTPRINT::Add(), BOOST_CHECK_EQUAL(), F_Fab, FOOTPRINT, FOOTPRINT::GraphicalItems(), BOARD_COMMIT::Push(), TOOL_MANAGER::RegisterTool(), COMMIT::Remove(), TOOL_MANAGER::SetEnvironment(), SKIP_UNDO, and text.
| BOOST_AUTO_TEST_CASE | ( | ReturnsBoardFromManager | ) |
Definition at line 107 of file test_board_commit.cpp.
References BOOST_CHECK_EQUAL(), BOARD_COMMIT::GetBoard(), TOOL_MANAGER::RegisterTool(), and TOOL_MANAGER::SetEnvironment().
| BOOST_AUTO_TEST_CASE | ( | ReusedCommitModifyAfterAdd | ) |
Definition at line 150 of file test_board_commit.cpp.
References COMMIT::Add(), BOOST_CHECK_EQUAL(), CHT_MODIFY, COMMIT::GetStatus(), COMMIT::Modify(), BOARD_COMMIT::Push(), TOOL_MANAGER::RegisterTool(), SEGMENT, TOOL_MANAGER::SetEnvironment(), and SKIP_UNDO.
| BOOST_AUTO_TEST_CASE | ( | RevertAfterDraggingAViaStackRestoresItsHops | ) |
Definition at line 231 of file test_board_commit.cpp.
References BOARD::Add(), LSET::AllCuMask(), LSET::AllTechMask(), BOOST_CHECK_EQUAL(), PCB_VIA_STACK::EditFinish(), PCB_VIA_STACK::EditStart(), F_Cu, PCB_GROUP::GetBoardItems(), PCB_GENERATOR::GetPosition(), In2_Cu, PCB_VIA_STACK::Move(), PCB_VIA_STACK::Regenerate(), TOOL_MANAGER::RegisterTool(), BOARD_COMMIT::Revert(), BOARD::SetCopperLayerCount(), BOARD::SetEnabledLayers(), PCB_VIA_STACK::SetEndLayer(), TOOL_MANAGER::SetEnvironment(), PCB_GENERATOR::SetPosition(), PCB_VIA_STACK::SetStartLayer(), PCB_VIA_STACK::SetViaDrill(), PCB_VIA_STACK::SetViaSize(), and PCB_VIA_STACK::Update().
| BOOST_AUTO_TEST_CASE | ( | UpdateOutsideAnEditIsInert | ) |
Definition at line 333 of file test_board_commit.cpp.
References BOARD::Add(), LSET::AllCuMask(), LSET::AllTechMask(), F_Cu, PCB_GROUP::GetBoardItems(), In2_Cu, PCB_VIA_STACK::Regenerate(), TOOL_MANAGER::RegisterTool(), BOARD::SetCopperLayerCount(), BOARD::SetEnabledLayers(), PCB_VIA_STACK::SetEndLayer(), TOOL_MANAGER::SetEnvironment(), PCB_GENERATOR::SetPosition(), PCB_VIA_STACK::SetStartLayer(), PCB_VIA_STACK::SetViaDrill(), PCB_VIA_STACK::SetViaSize(), and PCB_VIA_STACK::Update().