diff --git a/qa/eeschema/test_sch_item.cpp b/qa/eeschema/test_sch_item.cpp index 0b42183957..660b2b4646 100644 --- a/qa/eeschema/test_sch_item.cpp +++ b/qa/eeschema/test_sch_item.cpp @@ -78,13 +78,22 @@ static SCH_ITEM* Instatiate( KICAD_T aType, SCH_SHEET* sheet ) case SCH_SYMBOL_T: return new SCH_SYMBOL(); case SCH_SHEET_PIN_T: - // XXX: Sheet pins need to be manually placed on sheet item side. + // XXX (?): Sheet pins currently have to have their initial positions calculated manually. return new SCH_SHEET_PIN( sheet, wxPoint( sheet->GetPosition().x, sheet->GetPosition().y + Millimeter2iu( 40 ) ), "test pin" ); case SCH_SHEET_T: + { + SCH_SHEET* sheet = new SCH_SHEET(); + sheet->SetSize( wxSize( Millimeter2iu( 100 ), Millimeter2iu( 50 ) ) ); + + // XXX (?): Sheet fields currently have to be positioned with an additional method call. + sheet->AutoplaceFields( nullptr, false ); + return sheet; + } + case SCH_PIN_T: case SCHEMATIC_T: // TODO