Important Notice: Our web hosting provider recently started charging us for additional visits, which was unexpected. In response, we're seeking donations. Depending on the situation, we may explore different monetization options for our Community and Expert Contributors. It's crucial to provide more returns for their expertise and offer more Expert Validated Answers or AI Validated Answers. Learn more about our hosting issue here.

How do I initialize the testdata inside of a DDTTestCase?

initialize
0
Posted

How do I initialize the testdata inside of a DDTTestCase?

0

To connect the xml resource to your testclass you must implement the abstract method initContext() in your extension of the DDTTestCase class. This method will be executed implicitely during execution preparation. To facilitate usage there is another method provided my DDTTestCase. Here follows an example how to use the two methods in the default behavior. … public void initContext(){ initTestData(“MyClassResource”, “MyClassId”); } … By providing the two parameters of resource name and classId DDTTestCase will search for a resource of name DDT-MyClassResource.xml in the same ClassPath as the associated testclass . Inside of the resource it will look for the class id provided. If you provide an absolut resource name starting with / the class will use the resource name unchanged. … public void initContext(){ initTestData(“/my/own/path/to/MyClassResource.xml”, “MyClassId”); } … If you like to use the default selection scheme of you can simply write … public void initContext(){ i

What is your question?

*Sadly, we had to bring back ads too. Hopefully more targeted.

Experts123