Exemplo n.º 1
0
        public void EditIrtCalcDlgPepCountTest(EditIrtCalcDlg dlg, int numStandardPeps, int numLibraryPeps, string path, bool add)
        {
            RunUI(() =>
            {
                Assert.AreEqual(0, dlg.StandardPeptideCount);
                Assert.AreEqual(0, dlg.LibraryPeptideCount);

                dlg.CalcName = "Testing";
                dlg.OpenDatabase(path);

                Assert.AreEqual(numStandardPeps, dlg.StandardPeptideCount);
                Assert.AreEqual(numLibraryPeps, dlg.LibraryPeptideCount);
            });

            if (add)
            {
                var addDlg = ShowDialog <AddIrtPeptidesDlg>(dlg.AddResults);
                RunUI(() => addDlg.Action = AddIrtPeptidesAction.skip);
                var recalibrateDlg = ShowDialog <MultiButtonMsgDlg>(addDlg.OkDialog);
                OkDialog(recalibrateDlg, recalibrateDlg.Btn1Click);
            }

            RunUI(dlg.OkDialog);
            WaitForClosedForm(dlg);
        }
Exemplo n.º 2
0
        public void EditIrtCalcDlgPepCountTest(EditIrtCalcDlg dlg, int numStandardPeps, int numLibraryPeps, string path, bool add)
        {
            RunUI(() =>
            {
                Assert.AreEqual(0, dlg.StandardPeptideCount);
                Assert.AreEqual(0, dlg.LibraryPeptideCount);

                dlg.CalcName = "Testing";
                dlg.OpenDatabase(path);

                Assert.AreEqual(numStandardPeps, dlg.StandardPeptideCount);
                Assert.AreEqual(numLibraryPeps, dlg.LibraryPeptideCount);
            });

            if (add)
            {
                RunDlg <AddIrtPeptidesDlg>(dlg.AddResults, addDlg =>
                {
                    addDlg.Action = AddIrtPeptidesAction.skip;
                    addDlg.OkDialog();
                });
            }

            RunUI(dlg.OkDialog);
            WaitForClosedForm(dlg);
        }