testng-team / testng

TestNG testing framework
https://testng.org
Apache License 2.0
1.98k stars 1.02k forks source link

Dataproviders in TestNG #531

Closed saranya186b closed 7 years ago

saranya186b commented 10 years ago

Is there any possibility that dataproviders can take values from xml file and pass it as pojo objects into methods like insertemp(Employee emp).

aquintiliano commented 10 years ago

I'd like that data providers take values from xml and pass to code in @annotations, like parameters... something like @DataProvider(name="dataProvider") and in XML ... it'd be great!

FibreFoX commented 10 years ago

You could use something like Jackson to read JSON-files, or just create your objects via JAXB, doesn't have to be solved via TestNG itself. Have a look at the docu: https://github.com/FasterXML/jackson-dataformat-xml

krmahadevan commented 7 years ago

This is not really a bug but more of a question, which has been answered above.