18 January 2026:
Sahi Pro is an enterprise grade test automation platform which can automate web, mobile, API, windows and java based applications and SAP.
This forum is now archived and is in read-only mode. Please continue discussions on our improved new Sahi Pro Community forum.
Sahi Pro is an enterprise grade test automation platform which can automate web, mobile, API, windows and java based applications and SAP.
SendingEmail:getting error as "Java constructor for "net.sf.sahi.ant.Mailer" with arguments "string"
I am trying to send email using sahi after executing my script .
I have followed all the steps mentioned on "http://sahi.co.in/w/sending-emails"
Also I have set Sahi’s classpath but still not able to send email.
I am getting following error " Java constructor for "net.sf.sahi.ant.Mailer" with arguments "string,number,string,string,boolean" not found."
Can anyone please help me on this.
I have followed all the steps mentioned on "http://sahi.co.in/w/sending-emails"
Also I have set Sahi’s classpath but still not able to send email.
I am getting following error " Java constructor for "net.sf.sahi.ant.Mailer" with arguments "string,number,string,string,boolean" not found."
Can anyone please help me on this.
Best Answers
-
Hi Abhijeet,
If you're using Sahi OS,
please replace the following lines in your codevar $isSSL = true; // set to true if you use SSL var $mailer = new Packages.net.sf.sahi.ant.Mailer($host, $port, $username, $password, $isSSL);
withvar $mailer = new Packages.net.sf.sahi.ant.Mailer($host, $port, $username, $password);
If it still doesn't work for you, please let me know.
Regards.
Answers