in reply to Re^3: Read INI file
in thread Read INI file
or something similar, you will have something that the standard .INI file modules will understand. And you can add the feature of "turning a test case off" without removing a line from the [Test_suit_name] section. I use this format for one program's default .INI file where almost all options are turned off (0), by default. The user can see what can be enabled without having to read a separate doc and add a line to the .ini file. Just change a 0 to a 1.[Test_suit_name] Testcase1.txt = 1 Testcase2.txt = 0 TestCase3.txt = 1
Update: it is also possible to have something like: test_suite_names = test1 test2 test8 In that case you get a hash key of test_suite_names and the text to the right of the "=" wind up being a string that you can parse. If possible, I would "go with the flow" and use a syntax that the standard modules can deal with.
|
|---|