コード例 #1
0
        public void Test_LMFamily()
        {
            var listManager = new FamilyListMan(fContext);

            Assert.IsNotNull(listManager);

            var familyRec = fContext.Tree.XRefIndex_Find("F1") as GDMFamilyRecord;

            listManager.Fetch(familyRec);

            listManager.QuickFilter = "*";
            Assert.IsTrue(listManager.CheckFilter());
            listManager.QuickFilter = "* - *";
            Assert.IsTrue(listManager.CheckFilter());
            listManager.QuickFilter = "*alpha*";
            Assert.IsFalse(listManager.CheckFilter());

            var listView = Substitute.For <IListViewEx>();

            listManager.UpdateColumns(listView);
            var listItem = new GKListItem("", null);

            listManager.UpdateItem(0, listItem, familyRec);
        }
コード例 #2
0
ファイル: ListsTests.cs プロジェクト: PQYPLZXHGF/GEDKeeper
        public void Test_LMFamily()
        {
            var listManager = new FamilyListMan(fContext);

            Assert.IsNotNull(listManager);

            GEDCOMFamilyRecord famRec = fContext.Tree.XRefIndex_Find("F1") as GEDCOMFamilyRecord;

            listManager.Fetch(famRec);

            listManager.QuickFilter = "*";
            Assert.IsTrue(listManager.CheckFilter());
            listManager.QuickFilter = "* - *";
            Assert.IsTrue(listManager.CheckFilter());
            listManager.QuickFilter = "*alpha*";
            Assert.IsFalse(listManager.CheckFilter());

            var lvMock = new ListViewMock();

            listManager.UpdateColumns(lvMock);
            var listItem = new GKListItem("", null);

            listManager.UpdateItem(0, listItem, famRec);
        }