After poking around in the files installed by Delphi, I have found a file
"C:\Program Files\Embarcadero\RAD Studio\7.0\ObjRepos\en\UnitTestFrameworks.xml"
This file has a number of sections for setting options that affect the test case code generated by the test case wizard that gets invoked when you create a new test case unit. Most of these options are self-explanatory but it would be great to see some documentation.
In particular, I'd like to:
add a second TestClassComment.
have multiple options in the wizard's test case base class combo box. I am able to change the value of the single item in this list by changing the value of the node in the UnitTestFrameworks.xml file but cannot get multiple items to appear in the list.
Markup the test class and methods with some attributes.
For the moment I'm only looking at the Delphi Win 32 personality.
Am I on the right track here? Is documentation available or failing that, does anyone have any tips?
I don't think there is any documentation on this. If there is, David Intersimone at Embarcadero is who I'd ask for it.
Failing that, there are two options you might try.
The unit tests are only text files, so the second option wouldn't be any harder than trying to hack the wizard. You could create your own unit test wizard in Delphi and hook it into the tools menu quite easily.
If you wanted to, you could have it read your class files to create test skeletons for all of your methods, or create a command line tool to generate them.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With