MCPcopy Create free account
hub / github.com/IChooseYou/Reclass / testWorkspace_twoRootTree

Method testWorkspace_twoRootTree

tests/test_new_features.cpp:569–587  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

567 }
568
569 void testWorkspace_twoRootTree() {
570 auto tree = makeTwoRootTree();
571 QStandardItemModel model;
572 buildWorkspaceModel(&model, tree, "TwoRoot.rcx");
573
574 QCOMPARE(model.rowCount(), 1);
575 QStandardItem* project = model.item(0);
576
577 // 2 root struct children: Alpha and Bravo
578 QCOMPARE(project->rowCount(), 2);
579 QVERIFY(project->child(0)->text().contains("Alpha"));
580 QVERIFY(project->child(1)->text().contains("Bravo"));
581
582 // Each has 1 field child
583 QCOMPARE(project->child(0)->rowCount(), 1);
584 QVERIFY(project->child(0)->child(0)->text().contains("flagsA"));
585 QCOMPARE(project->child(1)->rowCount(), 1);
586 QVERIFY(project->child(1)->child(0)->text().contains("flagsB"));
587 }
588
589 void testWorkspace_richTree_rootCount() {
590 auto tree = makeRichTree();

Callers

nothing calls this directly

Calls 1

buildWorkspaceModelFunction · 0.85

Tested by

no test coverage detected