how to execute .xml file from TestNG framework

402 views
Skip to first unread message

Panikera

unread,
Aug 17, 2012, 6:37:58 AM8/17/12
to testng...@googlegroups.com
Hi All,

I am using web driver with testNG framework. In that frame work I am
executing multiple test cases from .xml file While I am executing, It is
not
showing "Run As TestNg" . what is the mistake i did, How to over come this
problem...

below is .xml file script..

<!DOCTYPE suite SYSTEM &quot;http://testng.org/testng-1.0.dtd&quot;>
<suitte name="my sample suite">

<test name="Application Login">
<classes>
<class name="tests.fileupload"></class>
</classes>
</test>

<test name="Selling Books Login">
<classes>
<class name="tests.toolTip"></class>
</classes>
</test>

</suitte>


Please let me know.....

Thanks In Advance..

Regards,
Raaj



--
View this message in context: http://testng.1065351.n5.nabble.com/how-to-execute-xml-file-from-TestNG-framework-tp16368.html
Sent from the testng-users mailing list archive at Nabble.com.

Roman Hiden

unread,
Aug 17, 2012, 4:57:03 PM8/17/12
to testng...@googlegroups.com
if you have eclipse plugin installed then just rig1) ht click on the xml file 2) Run As 3) TestNg

Panikera

unread,
Aug 18, 2012, 2:50:31 AM8/18/12
to testng...@googlegroups.com
Expand all
Print all
In new window

[testng-users] how to execute .xml file from TestNG framework
Inbox
x

Panikera
4:07 PM (20 hours ago)
Hi All, I am using web driver with testNG framework. In that frame work I am ...
Roman Hiden
2:27 AM (9 hours ago)
if you have eclipse plugin installed then just rig1) ht click on the xml file...
Roman Hiden [via TestNG]
2:27 AM (9 hours ago)
To post to this group, send email to [hidden email]. To unsubscribe from this...
Panikera Raj
12:18 PM (1 minute ago)

to Roman
Hi Roman,

         I am not getting Run as "TestNG". Just it is showing Run As "Run on Server " and "XSL Transformation"
these two futures only it's showing.. What is problem...

Thanks,
Shekar.

To post to this group, send email to [hidden email].
To unsubscribe from this group, send email to [hidden email].






Click here to Reply or Forward
0% full
Using 0.1 GB of your 10 GB
©2012 Google - Terms & Privacy
Last account activity: 12 hours ago
Details

Manoj Kapuganti

unread,
Aug 18, 2012, 3:05:41 AM8/18/12
to testng...@googlegroups.com

Change suitte to suite in your xml.

Best Regards,
Manoj Kapuganti

--
You received this message because you are subscribed to the Google Groups "testng-users" group.
To post to this group, send email to testng...@googlegroups.com.
To unsubscribe from this group, send email to testng-users...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/testng-users?hl=en.

Panikera

unread,
Aug 18, 2012, 4:15:38 AM8/18/12
to testng...@googlegroups.com
Hi Manoj,

        Thanks for your reply..

And while executing the .xml file in testNG framework here I am getting another type of error in console window
like...

org.testng.TestNGException:
Cannot find class in classpath: tests.frameWork
    at org.testng.xml.XmlClass.loadClass(XmlClass.java:80)
    at org.testng.xml.XmlClass.init(XmlClass.java:72)
    at org.testng.xml.XmlClass.<init>(XmlClass.java:58)
    at org.testng.xml.TestNGContentHandler.startElement(TestNGContentHandler.java:539)
    at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.startElement(Unknown Source)
    at com.sun.org.apache.xerces.internal.impl.dtd.XMLDTDValidator.startElement(Unknown Source)
    at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanStartElement(Unknown Source)
    at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(Unknown Source)
    at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(Unknown Source)
    at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
    at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source)
    at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source)
    at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(Unknown Source)
    at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(Unknown Source)
    at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source)
    at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl.parse(Unknown Source)
    at javax.xml.parsers.SAXParser.parse(Unknown Source)
    at org.testng.xml.SuiteXmlParser.parse(SuiteXmlParser.java:17)
    at org.testng.xml.SuiteXmlParser.parse(SuiteXmlParser.java:10)
    at org.testng.xml.Parser.parse(Parser.java:172)
    at org.testng.TestNG.initializeSuitesAndJarFile(TestNG.java:310)
    at org.testng.remote.RemoteTestNG.run(RemoteTestNG.java:88)
    at org.testng.remote.RemoteTestNG.initAndRun(RemoteTestNG.java:204)
    at org.testng.remote.RemoteTestNG.main(RemoteTestNG.java:175)

please let me know problem..

Thanks,
Shekar



On Sat, Aug 18, 2012 at 12:36 PM, Manoj Kapuganti [via TestNG] <[hidden email]> wrote:

Change suitte to suite in your xml.

Best Regards,
Manoj Kapuganti

To post to this group, send email to [hidden email].
To unsubscribe from this group, send email to [hidden email].

For more options, visit this group at http://groups.google.com/group/testng-users?hl=en.

--
You received this message because you are subscribed to the Google Groups "testng-users" group.
To post to this group, send email to [hidden email].
To unsubscribe from this group, send email to [hidden email].

For more options, visit this group at http://groups.google.com/group/testng-users?hl=en.



If you reply to this email, your message will be added to the discussion below:
http://testng.1065351.n5.nabble.com/how-to-execute-xml-file-from-TestNG-framework-tp16368p16387.html
To unsubscribe from how to execute .xml file from TestNG framework, click here.
NAML



View this message in context: Re: how to execute .xml file from TestNG framework

Panikera

unread,
Aug 18, 2012, 2:48:55 AM8/18/12
to testng...@googlegroups.com
Hi Roman,

         I am not getting Run as "TestNG". Just it is showing Run As "Run on Server " and "XSL Transformation"
these two futures only it's showing.. What is problem...

Thanks,
Shekar.

--
You received this message because you are subscribed to the Google Groups "testng-users" group.
To view this discussion on the web visit https://groups.google.com/d/msg/testng-users/-/Bec2YfDavqoJ.
To post to this group, send email to [hidden email].
To unsubscribe from this group, send email to [hidden email].

For more options, visit this group at http://groups.google.com/group/testng-users?hl=en.



If you reply to this email, your message will be added to the discussion below:
To unsubscribe from how to execute .xml file from TestNG framework, click here.
NAML

Satish kumar Poojari

unread,
Mar 7, 2014, 4:22:56 PM3/7/14
to testng...@googlegroups.com

if your package name is FabFurnishPackage and class name is registration then the code in xml should be

<classes>
<class name="FabFurnishPackage.registration">
</class>
Reply all
Reply to author
Forward
0 new messages