Esempio n. 1
0
        public void SendCurrentWeather()
        {
            UserList      userList   = new UserList();
            List <string> users      = userList.getUsers();
            WSResponce    respObject = new WSResponce();
            current       response   = new current();

            response = respObject.CurrentWeatherResponse(CurrentUrl);
            ComposeMessage newMessage = new ComposeMessage();
            string         message    = newMessage.CreateMessage(response);

            ChromeOptions options = new ChromeOptions();

            options.AddArgument(cache);
            driver = new ChromeDriver(options);

            StartPage startPage = new StartPage(driver);

            startPage.GoToUrl();
            foreach (string user in users)
            {
                startPage.OpenChat(user);
                startPage.SendMesage(message);
            }

            driver.Quit();
        }