I have 1 unit test method that needs several parameters. I would like to run this test once for each possible Cartesian value with a predefined list for each parameter. I assume that the parameters can go through the test context, but I do not want to connect to an external database.
For example: if I had 2 parameters with the following possible values, the test would be performed 6 times (the order does not matter). (Pseudo code)
p1 = { 1, 5, 10 }
p2 = { "blue", "red" }
test 1: ( 1, "red" )
test 2: ( 5, "red" )
test 3: ( 10, "red" )
test 4: ( 1, "blue" )
test 5: ( 5, "blue" )
test 6: ( 10, "blue" )
Note. I use the built-in testing of Visual Studio 2010, not NUnit or one of many other unit test frameworks.
Edit:
, . - / . 2 6 , . scenerio , - .