Пример #1
0
        public void deletePublihedFileRI()
        {
            //   string[] username = null;
               //     string[] password = null;

            XMLParse oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

             //   username = oXMLData.getData("settings/Credentials", "username");
            //    password = oXMLData.getData("settings/Credentials", "password");

            //Initializing the objects
            LoginHelper loginHelper = new LoginHelper(GetWebDriver());
            ClientsHelper clientHelper = new ClientsHelper(GetWebDriver());
            DeletePublishFileHelper deletePublishFileHelper = new DeletePublishFileHelper(GetWebDriver());
            var loginAsCorpHelper = new LoginAsCorpHelper(GetWebDriver());

            //Login with valid credential  Username
            loginAsCorpHelper.TypeText("EnterUsername", "selcorp");

            //Login with valid credential password
            loginAsCorpHelper.TypeText("EnterPassword", "seWelcome2");

            //Click On Login Button
            loginAsCorpHelper.ClickElement("ClickOnLoginButton");
            loginAsCorpHelper.WaitForWorkAround(3000);

            //Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

             //Click on Residual Income tab
             deletePublishFileHelper.ClickElement("ClickResidualIncomeTab");

            //Click to Import
            deletePublishFileHelper.redirectToPage();

            //Click On Import New button
            deletePublishFileHelper.ClickElement("ClickOnImportNew");

            //Processor
            deletePublishFileHelper.Select("ProcessorType", "First Data North");
            deletePublishFileHelper.WaitForWorkAround(3000);

            //Reporting Period
            deletePublishFileHelper.Select("ReportingPeriod", "11");

            //File Date
            deletePublishFileHelper.ClickElement("FileDate");

            deletePublishFileHelper.ClickElement("ClickDate");

            String FileName = "D:\\pegqa\\TestAutomationProject\\PegasusTests\\Files\\FDN_Samples.csv";
            deletePublishFileHelper.Upload("SelectBrowseCSVFile", FileName);
            deletePublishFileHelper.WaitForWorkAround(4000);

            //Import
            deletePublishFileHelper.ClickElement("ClickOnImportBtn");
            deletePublishFileHelper.WaitForWorkAround(5000);

            //##################################  SET FILTER  ##################################

            //Select Filter ReportingPeriod
            deletePublishFileHelper.Select("SelectFiletReportingPeriod", "November 2015");

            // Select Processor Filer
            deletePublishFileHelper.Select("SelectProcessorFiler", "First Data North");

            //Select Filter FileFormat
            deletePublishFileHelper.Select("FilterFileFormat", "First Data North");

            //Select Filter ReportingPeriod
            deletePublishFileHelper.TypeText("FileName", "FDN_Samples");

            //Select Status
            deletePublishFileHelper.Select("SelectStatus", "Imported");

            //Click on delete icon
            deletePublishFileHelper.ClickElement("ClickOnCalculation");
            deletePublishFileHelper.WaitForWorkAround(4000);
        }
Пример #2
0
        public void TestDeletePublishedFileRi()
        {
            var oXmlData = new XMLParse();
            oXmlData.LoadXML("../../Config/ApplicationSettings.xml");

            // Initializing the objects
            var deletePublishFileHelper = new DeletePublishFileHelper(GetWebDriver());

            // Login with valid credential Username
            deletePublishFileHelper.TypeText("EnterUsername", "selcorp");

            // Login with valid credential password
            deletePublishFileHelper.TypeText("EnterPassword", "seWelcome2");

            // Click On Login Button
            deletePublishFileHelper.ClickElement("ClickOnLoginButton");

            // Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

            // Click on Residual Income tab
            deletePublishFileHelper.ClickElement("ClickResidualIncomeTab");

            // Click to Import
            deletePublishFileHelper.redirectToPage();

            // Click On Import New button
            deletePublishFileHelper.ClickElement("ClickOnImportNew");

            // Processor
            deletePublishFileHelper.Select("ProcessorType", "First Data North");
            deletePublishFileHelper.WaitForWorkAround(3000);

            // Reporting Period
            deletePublishFileHelper.Select("ReportingPeriod", "11");

            // File Date
            deletePublishFileHelper.TypeText("FileDate", "2015-05-21");

            var fileName = GetPath() + "images/FDN_Samples.csv";
            deletePublishFileHelper.Upload("SelectBrowseCSVFile", fileName);
            deletePublishFileHelper.WaitForWorkAround(4000);

            // Import
            deletePublishFileHelper.ClickElement("ClickOnImportBtn");
            deletePublishFileHelper.WaitForWorkAround(5000);

            // ##################################  SET FILTER  ##################################

            // Select Filter ReportingPeriod
            deletePublishFileHelper.Select("SelectFiletReportingPeriod", "November 2015");

            // Select Processor Filer
            deletePublishFileHelper.Select("SelectProcessorFiler", "First Data North");

            // Select Filter FileFormat
            deletePublishFileHelper.Select("FilterFileFormat", "First Data North");

            // Select Filter ReportingPeriod
            deletePublishFileHelper.TypeText("FileName", "FDN_Samples");

            // Select Status
            deletePublishFileHelper.Select("SelectStatus", "Imported");

            // Click on delete icon
            deletePublishFileHelper.ClickElement("ClickOnCalculation");
            deletePublishFileHelper.WaitForWorkAround(4000);
        }