On Wed, Jan 14, 2009 at 11:29:40PM +0530, Balbir Singh wrote: > * Dhaval Giani <[email protected]> [2009-01-14 23:12:00]: > > > On Wed, Jan 07, 2009 at 11:35:21PM +0530, Sudhir Kumar wrote: > > > This is a try to use a sample configuration file for running libcgroup > > > testing. The patch attaches a sample configuration file to be used. The > > > plan for testing each input api is to run a particular funcition with > > > respect to that api. The function is supposed to test all possible > > > scenarios for that api.(e.g. calling api without initializing cgroup, > > > with diff invalid/NULL parameters, calling it twice etc). > > > > > > I have couple of doubts with respect to the implementation: > > > 1. How should the test be run? A script running the binary or just > > > binary? > > > 1a. If only binary then we may need a small string library as there > > > will be lot of string manipulations while parsing. > > > 1b. If a script then how to fill data structure of binary if we parse in > > > script. > > > > > > 2. How to ensure a clean state of the system in case of some failure. > > > 3. Shall I put separate options in .conf file for no,single and > > > multimount. > > > 4. I am thinking to take input from user for the number of instances of > > > test to be run. For ex if I say > > > api,cgroup_create_cgroup,15 > > > then there will be 15 tasks in the task list running the corresponding > > > function. Is that good? > > > 5. Any other fields that need to be added. > > > > > > > > Sudhir, > > I don't like the format very much, I had something like the following > in mind > > [test] > id = 1 > name = "something" > threads = 10 > process = 10 > mount = "cpu, memory" > cpu.shares = "nnnn" > memory.limit_in_bytes = "lllll" > cleanup = true >
OK, I am quite confused on what means what. Can you please indulge me? :) (mainly what is id, and difference between process and threads, and what) > > and then use that for the tests, note the parameters are optional. You > could even go one step ahead and specify a flow. We should definitely > specify a parameter in the form of cleanup. I expect the configuration > file to be parsed by a shell script or a simple "C" program. If a > script parses it, it can specify this as parameters to the tests it > invokes. > > You could go one step further and specify the test cases directly > (provided the infrastructure can handle/support it) > > process = 10 > threads = 15 > [test flow] > cgroup_name="001" > cgroup_create_cgroup:p > cgroup_create_cgroup:f > ... > > etc, where p and f represent expected return code "pass" or "fail", > but I'd add test flow only much later, since it would need more formal > design and thought. > > I hope I answered your questions > > -- > Balbir -- regards, Dhaval ------------------------------------------------------------------------------ This SF.net email is sponsored by: SourcForge Community SourceForge wants to tell your story. http://p.sf.net/sfu/sf-spreadtheword _______________________________________________ Libcg-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/libcg-devel
