Example #1
0
        public CommunicationsResponse RetrieveSelectedBankAccountDetails(BankCommsCapsule capsule)
        {
            string address = "https://online.mbank.pl/pl/Login";
            CommunicationsResponse response = new CommunicationsResponse();

            ChromeDriver driver = new ChromeDriver();

            driver.Navigate().GoToUrl(address);

//            WebDriverWait wait = new WebDriverWait(driver, TimeSpan.FromSeconds(10));
            Thread.Sleep(3000);

            IWebElement login    = driver.FindElementByName("userID");
            IWebElement password = driver.FindElementByName("pass");

            login.SendKeys(capsule._login);
            password.SendKeys(capsule._password);

            password.Submit();


            driver.Navigate().GoToUrl("https://online.mbank.pl/pl#/accounts");
            Thread.Sleep(3000);
            // IWebElement account = driver.FindElementByName

            driver.Quit();
            return(response);
        }
Example #2
0
        public BankAccountDetails GiveAccountDetails(SingleAccountInfo info)
        {
            AccountInfoRequestFactory factory = new AccountInfoRequestFactory();
            BankCommsCapsule          capsule = factory.CreateBankCommunicationsCapsule(info);

            CommunicationsResponse resp = _selectedComms.RetrieveSelectedBankAccountDetails(capsule);//the part where magic happens

            AccountInfoResponseParser parser  = new AccountInfoResponseParser();
            BankAccountDetails        details = parser.FormAccountDetails(resp);

            return(details);
        }
Example #3
0
 internal BankAccountDetails FormAccountDetails(CommunicationsResponse resp)
 {
     throw new NotImplementedException();
 }
Example #4
0
        public CommunicationsResponse RetrieveSelectedBankAccountDetails(BankCommsCapsule capsule)
        {
            string address = "https://online.mbank.pl/pl/Login";
            CommunicationsResponse response = new CommunicationsResponse();

            ChromeDriver driver = new ChromeDriver();
            driver.Navigate().GoToUrl(address);

            //            WebDriverWait wait = new WebDriverWait(driver, TimeSpan.FromSeconds(10));
            Thread.Sleep(3000);

            IWebElement login = driver.FindElementByName("userID");
            IWebElement password = driver.FindElementByName("pass");

            login.SendKeys(capsule._login);
            password.SendKeys(capsule._password);

            password.Submit();

            driver.Navigate().GoToUrl("https://online.mbank.pl/pl#/accounts");
            Thread.Sleep(3000);
               // IWebElement account = driver.FindElementByName

            driver.Quit();
            return response;
        }
 internal BankAccountDetails FormAccountDetails(CommunicationsResponse resp)
 {
     throw new NotImplementedException();
 }