javax.mail.MessagingException: Connection refused

91 views
Skip to first unread message

Mike

unread,
Dec 15, 2016, 11:58:34 AM12/15/16
to Selenium Users
HI
When I run my test from Jenkins I get the error bellow I was wondering if any one can help?
Thanks
<br><b>Run TC_04 test case</b>
java.lang.RuntimeException: javax.mail.MessagingException: Connection refused;
  nested exception is:
	java.net.ConnectException: Connection refused
	at com.lanyon.selenium.EmailManager.<init>(EmailManager.java:247)
	at com.lanyon.selenium.EmailManager.<init>(EmailManager.java:236)
	at com.lanyon.selenium.EmailManager.waitForNewEmail(EmailManager.java:194)
	at com.selenium.scripts.passkey.smoketest.LoginVerificationTest.TC_04(LoginVerificationTest.java:63)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:606)
	at org.testng.internal.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:84)
	at org.testng.internal.Invoker.invokeMethod(Invoker.java:714)
	at org.testng.internal.Invoker.invokeTestMethod(Invoker.java:901)
	at org.testng.internal.Invoker.invokeTestMethods(Invoker.java:1231)
	at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:127)
	at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:111)
	at org.testng.TestRunner.privateRun(TestRunner.java:767)


Shawn McCarthy

unread,
Dec 15, 2016, 4:53:03 PM12/15/16
to Selenium Users
I'm not sure, but you might have better luck on a javax.mail mailing list.

Maybe the hostname is incorrect? Is it gmail? Are you using smtp.gmail.com ?

Mike

unread,
Dec 15, 2016, 4:59:21 PM12/15/16
to Selenium Users
HI 
Thanks yest it is Gmail .

Mike

unread,
Dec 15, 2016, 5:02:29 PM12/15/16
to Selenium Users
Hi 
Yes it is gmail and I am using http://smtp.gmail.com/
where the configuration should happen in jenking or in the box I have admin user to jenkins but I don't have access to the box where jenkins set so I can't ping or telnet to gmail to see if there is firewall blocking the SMTP.
Thanks


On Thursday, December 15, 2016 at 4:53:03 PM UTC-5, Shawn McCarthy wrote:

⇜Krishnan Mahadevan⇝

unread,
Dec 15, 2016, 10:06:27 PM12/15/16
to Selenium Users

Mike

Why not create a shell step in your Jenkins build wherein you try the telnet or ping to test connectivity and just run the job ? That would still be equal to you sshing into the Jenkins box and running it manually.


--
You received this message because you are subscribed to the Google Groups "Selenium Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to selenium-user...@googlegroups.com.
To post to this group, send email to seleniu...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/selenium-users/9f308d4d-3ab8-4f2c-b006-4bf347ecd4d9%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--

Thanks & Regards
Krishnan Mahadevan

"All the desirable things in life are either illegal, expensive, fattening or in love with someone else!"
My Scribblings @ http://wakened-cognition.blogspot.com/

My Technical Scribbings @ http://rationaleemotions.wordpress.com/

Reply all
Reply to author
Forward
0 new messages