예제 #1
0
        public void SendMail(string message)
        {
            string nomail = ConfigurationManager.AppSettings["LocalMachineName"];

            if (String.IsNullOrEmpty(nomail) == false)
            {
                string[] email = nomail.Split(';', ',');

                bool found = false;

                foreach (string lmn in email)
                {
                    if (Environment.MachineName.Contains(lmn))
                    {
                        found = true;
                        break;
                    }
                }

                if (found == false)
                {
                    MailResults.MailHeader mh = new MailResults.MailHeader();

                    string subject = "COMPLETED - Kurryer Test Automation for " + AppName + " [" + AppBrowser + "] ";
                    string body    = message;
                    MailResults.SendMessage(mh, subject, body);
                }
            }
        }
예제 #2
0
        public void SendMail(string message)
        {
            string nomail = ConfigurationManager.AppSettings["LocalMachineName"];

            if (String.IsNullOrEmpty(nomail) == false)
            {
                string[] email = nomail.Split(';', ',');

                bool found = false;

                foreach (string lmn in email)
                {
                    if (Environment.MachineName.Contains(lmn))
                    {
                        found = true;
                        break;
                    }
                }

                if (found == false)
                {
                    MailResults.MailHeader mh = new MailResults.MailHeader();

                    string subject = "COMPLETED - Kurryer Test Automation for "+ AppName +" [" + AppBrowser + "] ";
                    string body = message;
                    MailResults.SendMessage(mh, subject, body);
                }
            }
        }