コード例 #1
0
        public static bool VerifyLabAddress(String address, String city, String state, String country)
        {
            try
            {
                WebTable_SearchCriteriaItemList list = new WebTable_SearchCriteriaItemList();
                list.AddSearchItem(new WebTable_SearchCriteriaItem(0, address, TableColumnContentType.Text));
                list.AddSearchItem(new WebTable_SearchCriteriaItem(1, city, TableColumnContentType.Text));
                list.AddSearchItem(new WebTable_SearchCriteriaItem(1, state, TableColumnContentType.Text));
                list.AddSearchItem(new WebTable_SearchCriteriaItem(1, country, TableColumnContentType.Text));

                IControl labAddressRow = WebTableUtilities.Table_FindRow(DL_Lab_MRR_Table.MrrTable, list, 0);
                IControl cellText      = WebTableUtilities.GetCell(labAddressRow, 0);
                String   mRR_PageName  = Control_PropertyUtilities.GetText(cellText);

                if ((address.Equals(mRR_PageName, StringComparison.InvariantCultureIgnoreCase)) & (city.Equals(mRR_PageName, StringComparison.InvariantCultureIgnoreCase)) & (state.Equals(mRR_PageName, StringComparison.InvariantCultureIgnoreCase)) & (country.Equals(mRR_PageName, StringComparison.InvariantCultureIgnoreCase)))
                {
                    return(true);
                }
            }
            catch (Exception e)
            {
                new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
            }
            return(false);
        }
コード例 #2
0
 public static bool ExpandEvent(String eventName, out String identifier)
 {
     identifier = String.Empty;
     try
     {
         ReadOnlyCollection <IControl> rows = WebTableUtilities.GetRows(DL_CRF_PDEP_EventsPage.EventsTable);
         foreach (IControl row in rows)
         {
             if (Control_PropertyUtilities.IsControlVisible(row))
             {
                 IControl cell = WebTableUtilities.GetCell(row, 0);
                 if (Control_PropertyUtilities.GetText(cell).Equals(eventName, StringComparison.InvariantCultureIgnoreCase))
                 {
                     IControl expandCollapseImage = WebTableUtilities.GetElement(row, String.Empty, 0, TableColumnContentType.Image);
                     bool     found       = false;
                     String   imageSource = Control_PropertyUtilities.GetAttributeValue(expandCollapseImage, "src", out found);
                     if (found)
                     {
                         identifier = Control_PropertyUtilities.GetAttributeValue(row, "identifier", out found);
                         if (imageSource.Contains("menu_expand.gif"))
                         {
                             return(Control_ActionUtilities.Click(expandCollapseImage, String.Empty));
                         }
                         return(imageSource.Contains("menu_collapse.gif"));
                     }
                 }
             }
         }
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
コード例 #3
0
 public static bool FormQuestion(IEnumerable <FormQuestion> Questions)
 {
     try
     {
         IControl QuestionsTable = DS_Forms.QuestionsTable;
         foreach (FormQuestion question in Questions)
         {
             WebTable_SearchCriteriaItemList searchList = new WebTable_SearchCriteriaItemList();
             searchList.AddSearchItem(new WebTable_SearchCriteriaItem(1, question.Question, TableColumnContentType.Link));
             IControl row = WebTableUtilities.Table_FindRow(QuestionsTable, searchList, 2);
             if (!Control_PropertyUtilities.IsControlNull(row))
             {
                 Control_ActionUtilities.Click(row, "Question not visible");
                 string domainItem = Control_PropertyUtilities.GetText(DS_Forms.LabMappingFormItemName);
                 if (!domainItem.Equals(question.DomainItem))
                 {
                     return(false);
                 }
             }
         }
         return(true);
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
コード例 #4
0
 public static bool AddCommentsToAFlatQuestion(string QuestionPrompt, string Comments)
 {
     try
     {
         if (SelectAddCommentElementForFlatQuestion(QuestionPrompt))
         {
             BrowserUtilities.SwitchToFrame();
             string QuestText = Control_PropertyUtilities.GetText(DL_CRFPage.GetQuestionOnAddCommentModal);
             if (!QuestText.Contains(QuestionPrompt))
             {
                 Control_ActionUtilities.LogException("Verify question prompt on add comments modal.", "Question is not displayed correctly", string.Empty);
                 return(false);
             }
             IControl CommentsTextBox = DL_CRFPage.GetTextAreaOnAddCommentModal;
             Control_ActionUtilities.Textbox_SetText(CommentsTextBox, Comments, "Unable to set comments for the question " + QuestionPrompt);
             IControl SaveButton = DL_CRFPage.GetButtonOnAddCommentModal("Save");
             Control_ActionUtilities.ClickModalButton(SaveButton);
             BrowserUtilities.SwitchToWindow();
             return(true);
         }
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
コード例 #5
0
 public static bool VerifyTheValuesInChangeHistory(string field, string value)
 {
     Utilities.BrowserUtilities.SwitchToFrame();
     try
     {
         if (field.Equals("Lab Name"))
         {
             string labName = Control_PropertyUtilities.GetText(DL_Lab_Mrr_AuditHistory.LabNameInChangeHistoryWindow);
             return(labName.Equals(value));
         }
         else if (field.Equals("Lab TestName"))
         {
             string labTestName = Control_PropertyUtilities.GetText(DL_Lab_Mrr_AuditHistory.LabTestNameInChangeHistoryWindow);
             return(labTestName.Equals(value));
         }
         else if (field.Equals("Heading"))
         {
             string heading = Control_PropertyUtilities.GetText(DL_Lab_Mrr_AuditHistory.HeadingInChangeHistoryWindow);
             return(heading.Equals(value));
         }
         else if (field.Equals("Ref ID"))
         {
             string refId = Control_PropertyUtilities.GetText(DL_Lab_Mrr_AuditHistory.RefIDInChangeHistoryWindow);
             return(refId.Contains(value));
         }
         // Utilities.BrowserUtilities.SwitchToWindow();
     }
     catch (Exception e)
     {
         new Reports.DebugLog.DebugLogGenerator().WriteException(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     Utilities.BrowserUtilities.SwitchToWindow();
     return(false);
 }
コード例 #6
0
        static bool IsDataMatched(Mrr_ChangeHistoryData data, IControl historyRow)
        {
            try
            {
                IControl dateTimeCell       = DL_Lab_Mrr_AuditHistory.GetDateTimeCell_Row(historyRow);
                IControl referenceRangeCell = DL_Lab_Mrr_AuditHistory.GetReferenceRangeCell_Row(historyRow);
                IControl actionCell         = DL_Lab_Mrr_AuditHistory.GetActionCell_Row(historyRow);

                String dateTimeText = Control_PropertyUtilities.GetText(dateTimeCell);
                dateTimeText.Trim();
                String referenceRangeText = Control_PropertyUtilities.GetText(referenceRangeCell);
                referenceRangeText.Trim();
                String actionText = Control_PropertyUtilities.GetText(actionCell);

                if (!dateTimeText.Contains(data.DateTime.Replace("\\r", "\r")))
                {
                    return(false);
                }
                if (!referenceRangeText.Equals(data.ReferenceRange.Replace("\\r", "\r"), StringComparison.InvariantCultureIgnoreCase))
                {
                    return(false);
                }
                if (!actionText.Equals(data.Action, StringComparison.InvariantCultureIgnoreCase))
                {
                    return(false);
                }
                return(true);
            }
            catch (Exception e)
            {
            }
            return(false);
        }
コード例 #7
0
        public static bool EnrollAPatient(string PatientID, EnrollPatientData PatientData)
        {
            bool isEnrollSuccessful = false;

            if (Control_PropertyUtilities.GetText(DL_PatientsPage.SelectedPatient) != PatientID)
            {
                Control_ActionUtilities.LogException("Verification of Patient on selecting a patient.", "Patient detail is not displayed as " + PatientID + " on the screen.", string.Empty);
                return(false);
            }
            string status = Control_PropertyUtilities.GetText(DL_PatientsPage.SelectedPatientStatus);

            if (status != "Screened")
            {
                Control_ActionUtilities.LogException("Verification of Patient status on patient details screen.", "Patient status detail is displayed as " + status + " on the screen.", string.Empty);
                return(false);
            }
            if (BP_ActionPaletteUtilities.InvokeActionPaletteLink("Enroll Patient", DL_PatientsPage.GetPatientActionPaletteID("Patient Actions")))
            {
                if (FillEnrollPatientCRF(PatientData))
                {
                    //Control_ActionUtilities.Click(DL_PatientsPage.EntryCompleteChkBox, "Unable to select Entry Complete checkbox.");
                    isEnrollSuccessful = Control_ActionUtilities.SubmitSaveNCloseButton(DL_CRFPage.SaveNCloseButton_CRF, "Unable to Enroll patient.");
                }
            }
            if (isEnrollSuccessful)
            {
                status = Control_PropertyUtilities.GetText(DL_PatientsPage.SelectedPatientStatus);
                if (status != "Enrolled")
                {
                    isEnrollSuccessful = false;
                }
            }
            return(isEnrollSuccessful);
        }
コード例 #8
0
 static IControl GetFormRadioButtonForFlag(List <IControl> eventFormRows, String formName, String radioButtonName)
 {
     foreach (IControl formRow in eventFormRows)
     {
         ReadOnlyCollection <IControl> cells = SyncUtilities.FindVisibleElements_Parent(formRow.WebElement, By.TagName("td"));
         if (cells.Count > 6)
         {
             if (formName.Equals(Control_PropertyUtilities.GetText(cells[0]), StringComparison.InvariantCultureIgnoreCase))
             {
                 if (radioButtonName.Equals("No Change", StringComparison.InvariantCultureIgnoreCase))
                 {
                     return(SyncUtilities.FindVisibleElement_Parent(cells[2].WebElement, By.TagName("input")));
                 }
                 else if (radioButtonName.Equals("Mark Required", StringComparison.InvariantCultureIgnoreCase))
                 {
                     return(SyncUtilities.FindVisibleElement_Parent(cells[3].WebElement, By.TagName("input")));
                 }
                 else if (radioButtonName.Equals("Mark All", StringComparison.InvariantCultureIgnoreCase))
                 {
                     return(SyncUtilities.FindVisibleElement_Parent(cells[4].WebElement, By.TagName("input")));
                 }
                 else if (radioButtonName.Equals("Unmark All", StringComparison.InvariantCultureIgnoreCase))
                 {
                     return(SyncUtilities.FindVisibleElement_Parent(cells[5].WebElement, By.TagName("input")));
                 }
             }
         }
     }
     return(null);
 }
コード例 #9
0
        public static bool VerifylabsDropDownValues(List <DropDownInfo> dropdownInfoList, String fieldName)
        {
            try
            {
                List <string> dropdown = new List <string>();
                foreach (DropDownInfo dropdownInfo in dropdownInfoList)
                {
                    dropdown.Add(dropdownInfo.Dropdown);
                }

                IControl dropdowncontrol = DS_StudyProperties.LabDropDown;

                Control_ActionUtilities.Click(dropdowncontrol, "Not able to click on dropdowncontrol");
                IControl selectValueInDropdown = DS_StudyProperties.LabDropDownOptions;

                string        selectValue    = Control_PropertyUtilities.GetText(selectValueInDropdown);
                bool          found          = false;
                List <String> dropdownvalues = Control_ActionUtilities.Dropdown_GetItems(dropdowncontrol, out found);
                if (found)
                {
                    bool comparison = DL_Lab_MRR_Table.AreListsEqual(dropdown, dropdownvalues);
                }
                return(true);
            }

            catch (Exception e)
            {
                new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
            }
            return(false);
        }
コード例 #10
0
        static IControl GetFormRow(String eventName, String formName, out IControl formCell)
        {
            formCell = null;
            String identifier = String.Empty;

            try
            {
                if (ExpandEvent(eventName, out identifier) && !String.IsNullOrEmpty(identifier))
                {
                    ReadOnlyCollection <IControl> rows = DL_CRF_PDEP_EventsPage.GetRowsEventRows(identifier);
                    foreach (IControl row in rows)
                    {
                        if (Control_PropertyUtilities.IsControlVisible(row))
                        {
                            formCell = WebTableUtilities.GetCell(row, 2);
                            String formText = Control_PropertyUtilities.GetText(formCell);
                            if (formName.Equals(formText, StringComparison.InvariantCultureIgnoreCase))
                            {
                                return(row);
                            }
                        }
                    }
                }
            }
            catch (Exception e)
            {
                new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
            }
            return(null);
        }
コード例 #11
0
 public static IControl GetFormCheckbox(String formName)
 {
     try
     {
         IControl formsTable = SyncUtilities.FindVisibleElement(By.Id("UnscheduledEvent_chkList"));
         ReadOnlyCollection <IControl> rows = SyncUtilities.FindVisibleElements_Parent(formsTable.WebElement, By.TagName("tr"));
         foreach (IControl c in rows)
         {
             IControl formLabel = SyncUtilities.FindElement(By.TagName("label"));
             if (!Control_PropertyUtilities.IsControlNull(formLabel))
             {
                 String labelText = Control_PropertyUtilities.GetText(formLabel);
                 if (labelText.Equals(formName, StringComparison.InvariantCultureIgnoreCase))
                 {
                     return(new Control(c.WebElement.FindElement(By.TagName("input"))));
                     //return SyncUtilities.FindElement(By.TagName("input"));
                 }
             }
         }
     }
     catch (Exception e)
     {
     }
     return(null);
 }
コード例 #12
0
 public static bool EnterReason(String reason)
 {
     try
     {
         bool retVal = false;
         BrowserUtilities.SwitchToFrame();
         try
         {
             IControl modalHeaderLabel = DL_ModalWindow_ResetCRF.TitleLabel_Step2;
             if (!Control_PropertyUtilities.IsControlNull(modalHeaderLabel))
             {
                 String headerText = Control_PropertyUtilities.GetText(modalHeaderLabel);
                 if (headerText.Equals("Reset Form", StringComparison.InvariantCultureIgnoreCase))
                 {
                     retVal = Control_ActionUtilities.Textbox_SetText(DL_ModalWindow_ResetCRF.ReasonTextArea, reason, String.Empty);
                 }
             }
         }
         catch (Exception e)
         {
             new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
         }
         BrowserUtilities.SwitchToWindow();
         return(retVal);
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
コード例 #13
0
        public static bool VerifyJobStatus(String process, String expectedStatus)
        {
            int  i     = 0;
            bool found = false;

            try
            {
                while (i < 60 && !found)
                {
                    BrowserUtilities.RefreshPage();
                    IControl cell = GetStatusCell(process, expectedStatus);

                    if (!Control_PropertyUtilities.IsControlNull(cell))
                    {
                        String actualText = Control_PropertyUtilities.GetText(cell);
                        found = actualText.Equals(expectedStatus, StringComparison.InvariantCultureIgnoreCase);
                    }
                    Thread.Sleep(5000);
                    ++i;
                }
            }
            catch (Exception e)
            {
            }
            return(found);
        }
コード例 #14
0
        public static IControl GetCollapsedTableRow(String tableName, int rowNumber)
        {
            IControl tableNameHost = null;
            IControl tableHost     = GetTableHost(tableName, rowNumber, out tableNameHost);
            IReadOnlyCollection <IControl> rows = SyncUtilities.FindElements_Parent(tableHost.WebElement, By.ClassName("HeaderRowOff"));

            foreach (IControl row in rows)
            {
                IReadOnlyCollection <IControl> cells = SyncUtilities.FindElements_Parent(row.WebElement, By.ClassName("tdCollapseRowNum"));
                foreach (IControl cell in cells)
                {
                    String cellText = Control_PropertyUtilities.GetText(cell);
                    if (cellText.EndsWith("." + rowNumber + "."))
                    {
                        if (Control_ActionUtilities.IsClickable(row.WebElement))
                        {
                            return(row);
                        }
                        else
                        {
                            return(null);
                        }
                    }
                }
            }
            return(null);
        }
コード例 #15
0
        public static bool VerifyDetailsOnPatientDetailsPage(string Patient, string Status, string Protocol, string PrimaryInvestigator)
        {
            bool verification = true;

            if (Patient != string.Empty)
            {
                if (Control_PropertyUtilities.GetText(DL_PatientsPage.SelectedPatient) != Patient)
                {
                    verification = false;
                }
            }
            if (Status != string.Empty)
            {
                if (Control_PropertyUtilities.GetText(DL_PatientsPage.SelectedPatientStatus) != Status)
                {
                    verification = false;
                }
            }
            if (Protocol != string.Empty)
            {
                if (Control_PropertyUtilities.GetText(DL_PatientsPage.SelectedPatientProtocol) != Protocol)
                {
                    verification = false;
                }
            }
            if (PrimaryInvestigator != string.Empty)
            {
                if (Control_PropertyUtilities.GetText(DL_PatientsPage.SelectedPatientPrimaryInvest) != PrimaryInvestigator)
                {
                    verification = false;
                }
            }
            return(verification);
        }
コード例 #16
0
        static List <IControl> GetEventFormRowsForFlag(ReadOnlyCollection <IControl> tableRows, String eventName)
        {
            List <IControl> eventFormRows = new List <IControl>();

            try
            {
                bool isEventMatched = false;
                foreach (IControl row in tableRows)
                {
                    IControl eventNameLabel = null;
                    if (IsEventRowForFlag(row, eventName, out eventNameLabel))
                    {
                        String actualEventNameOld = Control_PropertyUtilities.GetText(eventNameLabel);
                        String actualEventNameNew = actualEventNameOld.Replace("(Select all in event)", "");
                        isEventMatched = eventName.Equals(actualEventNameNew.Trim(), StringComparison.InvariantCultureIgnoreCase);
                    }
                    else
                    {
                        if (isEventMatched)
                        {
                            IControl formRow = SyncUtilities.FindVisibleElement_Parent(row.WebElement, By.TagName("span"));
                            if (!Control_PropertyUtilities.IsControlNull(formRow))
                            {
                                eventFormRows.Add(row);
                            }
                        }
                    }
                }
                return(eventFormRows);
            }
            catch (Exception e)
            {
            }
            return(eventFormRows);
        }
コード例 #17
0
        public static bool VerifyValuesInDropdown(List <DropDownInfo> dropdownInfoList, String fieldName)
        {
            try
            {
                List <string> dropdown = new List <string>();
                foreach (DropDownInfo dropdownInfo in dropdownInfoList)
                {
                    dropdown.Add(dropdownInfo.Dropdown);
                }

                IControl dropdowncontrol = DL_Lab_MRR_Table.GetDropdownInvoker(fieldName);
                Control_ActionUtilities.Click(dropdowncontrol, "Not able to click on dropdowncontrol");
                IControl selectValueInDropdown = DL_Lab_MRR_Table.GetSelectValueFromDropdown;
                string   selectValue           = Control_PropertyUtilities.GetText(selectValueInDropdown);
                ReadOnlyCollection <IControl> dropdowncontrollist = DL_Lab_MRR_Table.GetDropdownItems();
                List <string> dropdownvalues = new List <string>();
                // dropdownvalues.Add(selectValue);
                foreach (IControl control in dropdowncontrollist)
                {
                    string dropdownvalue = Control_PropertyUtilities.GetText(control);
                    dropdownvalues.Add(dropdownvalue);
                }
                bool comparison = DL_Lab_MRR_Table.AreListsEqual(dropdown, dropdownvalues);
                return(comparison);
            }
            catch (Exception e)
            {
                new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
            }
            return(false);
        }
コード例 #18
0
        static bool IsInThawPatientsPage()
        {
            IControl titleSpan = SyncUtilities.FindVisibleElement(By.Id("PatientsFreezeLock_lblPatients"));

            if (!Control_PropertyUtilities.IsControlNull(titleSpan))
            {
                return(Control_PropertyUtilities.GetText(titleSpan).Equals("Thaw Patients", StringComparison.InvariantCultureIgnoreCase));
            }
            return(false);
        }
コード例 #19
0
        public static bool FindValueInUnit(String emptyValue)
        {
            IControl unitCell  = WebTableUtilities.GetCell(DL_Lab_MRR_Table.GetFirstRow, 11);
            string   unitValue = Control_PropertyUtilities.GetText(unitCell);

            if (unitValue != null)
            {
                return(true);
            }
            return(true);
        }
コード例 #20
0
        public static String GetErrorString(String columnName)
        {
            IControl statusRow = WebTableUtilities.Table_FindRow(DL_AddLabPage.AddLabTable, GetSearchItemList(columnName));
            IControl span      = WebTableUtilities.GetElement(statusRow, String.Empty, 1, TableColumnContentType.Span);

            if (Control_PropertyUtilities.IsControlVisible(span))
            {
                return(Control_PropertyUtilities.GetText(span));
            }
            return(String.Empty);
        }
コード例 #21
0
 public static bool VerifyErrorMessage(String bodyMessageText_Partial)
 {
     try
     {
         return(Control_PropertyUtilities.GetText(ImportLabDictionaryPage.ImportLabDictError).Contains(bodyMessageText_Partial));
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
コード例 #22
0
 protected static bool IsQuestionPromptAvailable(ReadOnlyCollection <IControl> questionParts, String questionPrompt)
 {
     foreach (IControl c in questionParts)
     {
         String text = Control_PropertyUtilities.GetText(c);
         if (text.Equals(questionPrompt))
         {
             return(true);
         }
     }
     return(false);
 }
コード例 #23
0
 internal static bool IsModalExist_CheckHeaderText(String titleText)
 {
     try
     {
         return(titleText.Equals(Control_PropertyUtilities.GetText(DL_ModalWindow.Header).Trim()));
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
コード例 #24
0
 internal static bool IsModalExist_CheckBodyMessage(String bodyMessageText_Partial)
 {
     try
     {
         return(Control_PropertyUtilities.GetText(DL_ModalWindow_ResetSession.Message).Contains(bodyMessageText_Partial));
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
コード例 #25
0
        public static bool ApplyFilter(String columnName, string filterText, String filterCriteria)
        {
            try
            {
                IControl filterIcon          = DL_Lab_MRR_Table_Changes.GetColumnFilterLink(columnName);
                bool     isFilterIconClicked = Control_ActionUtilities.Click(filterIcon, String.Empty);

                bool isDropdownClicked = Control_ActionUtilities.Click(DL_Lab_MRR_Table.FilterDropDownIcon, String.Empty);

                IControl filterCriteriaItem = DL_Lab_MRR_Table.GetActiveFilterItem(filterCriteria);
                if ((Control_PropertyUtilities.GetText(filterCriteriaItem)).Equals(filterCriteria))
                {
                    bool isFilterCriteriaClicked = Control_ActionUtilities.Click(filterCriteriaItem, String.Empty);
                }


                IControl filterTextbox;
                if (columnName.Equals("Ref ID") || columnName.Equals("From Age") || columnName.Equals("To Age"))
                {
                    filterTextbox = DL_Lab_MRR_Table.FilterTextBox;
                    if (filterTextbox != null)
                    {
                        bool     isFilterTextSet = Control_ActionUtilities.Textbox_SetText1(filterTextbox, filterText, String.Empty);
                        IControl filterButton    = DL_Lab_MRR_Table.FilterButton;
                        Control_ActionUtilities.Click(filterButton, String.Empty);
                    }
                }
                else if (columnName.Equals("Gender"))
                {
                    filterTextbox = DL_Lab_MRR_Table.FilterTextBox;
                    Control_ActionUtilities.Textbox_SetText(filterTextbox, filterText, String.Empty);
                    IControl filterButton = DL_Lab_MRR_Table.FilterButton;
                    Control_ActionUtilities.Click(filterButton, String.Empty);
                }
                else if (columnName.Equals("Start Date") || columnName.Equals("End Date"))
                {
                    filterTextbox = DL_Lab_MRR_Table_Changes.FilterTextBoxForDateInputFieldInMRRTable;
                    Control_ActionUtilities.Textbox_SetText1(filterTextbox, filterText, String.Empty);
                    System.Threading.Thread.Sleep(1000);
                    IControl filterButton = DL_Lab_MRR_Table.FilterButton;
                    string   filterbutton = Control_PropertyUtilities.GetText(filterButton);
                    System.Threading.Thread.Sleep(3000);
                    Control_ActionUtilities.Click(filterButton, String.Empty);
                }
            }
            catch (Exception e)
            {
                new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
                return(false);
            }
            return(true);
        }
コード例 #26
0
 public static bool IsModalExist_CheckHeaderAndMessage(String titleText, String bodyMessageText_Partial)
 {
     try
     {
         return(titleText.Equals(Control_PropertyUtilities.GetText(CodeListsItemDeleteDialog.Header).Trim()) &&
                Control_PropertyUtilities.GetText(CodeListsItemDeleteDialog.LMSPopup).Contains(bodyMessageText_Partial));
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
コード例 #27
0
 public static bool VerifyThePageLoaded(string QueryField)
 {
     try
     {
         string Page = Control_PropertyUtilities.GetText(ScriptingPage.QueryPage);
         return(Page.Contains(QueryField));
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
コード例 #28
0
 public static bool IsModalExist_CheckHeaderTextAndErrorLinkMessage(String titleText, String bodyMessageText_Partial)
 {
     try
     {
         return(titleText.Equals(Control_PropertyUtilities.GetText(StudyVerificationMessagesPopup.SVRMessagesHeader).Trim()) &&
                Control_PropertyUtilities.GetText(StudyVerificationMessagesPopup.SVRMessagesErrorLinkMessage).Contains(bodyMessageText_Partial));
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
コード例 #29
0
 public static bool DeleteJobsModalExist_CheckHeaderTextAndBodyMessage(String titleText, String bodyMessageText_Partial)
 {
     try
     {
         return(titleText.Equals(Control_PropertyUtilities.GetText(DS_ConfirmationPopup.DeleteJobsHeader).Trim()) &&
                Control_PropertyUtilities.GetText(DS_ConfirmationPopup.DeleteJobsMessage).Contains(bodyMessageText_Partial));
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }
コード例 #30
0
 public static bool IsSiteDetailsPageOpened(String site)
 {
     try
     {
         IControl siteLabel = DL_SiteDetailsPage.Site;
         return(Control_PropertyUtilities.GetText(siteLabel).Equals(site, StringComparison.InvariantCultureIgnoreCase));
     }
     catch (Exception e)
     {
         new DebugLogGenerator().WriteException(MethodBase.GetCurrentMethod().DeclaringType.Name, MethodBase.GetCurrentMethod().Name, e);
     }
     return(false);
 }