Virtual user, iteration, test in Load Test RRS feed

  • Question

  • Context: I have

    - 1 test to run

    - 100 iterations

    - 100 users

    Question: How can i make each user run 1 test and then terminate so that no user can run more than 1 time?



    Wednesday, April 3, 2013 7:08 AM


All replies

  • The scenario has a "percentage of new users" property. See (for example) page 18 of "Visual Studio Performance Testing Quick Reference Guide" (Version 3.6), see http://vsptqrg.codeplex.com/ . The Codeplex document has lots of other good information about web and load testing.

    Another possibility is to add a second test that does nothing significant, but has very long think times. Then set the test mix to "Test mix based on sequential test order".



    • Marked as answer by like.no.other Thursday, April 4, 2013 2:45 AM
    • Unmarked as answer by like.no.other Friday, April 5, 2013 3:22 AM
    Wednesday, April 3, 2013 8:24 AM
  • You can set your test as "initialization test"
    Wednesday, April 3, 2013 10:50 AM
  • Adrian,

    Thanks for your suggestion. "One time user" is exactly what I need, just dont know how to get it done. I set "Percentage of New Users" to 100 and then just only 549 users loaded for 1500 tests!

    About another solution, It might give the different result since vusers keep ocupying resource.

    Any other suggestion?

    Thanks again,


    Thursday, April 4, 2013 2:23 AM
  • Hi Tal

    And...how initialization test in test mix can prevent v user from executing test second time?



    Thursday, April 4, 2013 2:26 AM
  • I agree... set "percentage of new users" to 100.

    Do you truly want each virtual user to only run once?  Setting the specified field to 100 will guarantee that each test is executed as a new connection... I'm guessing this is what you are after?

    Thursday, April 4, 2013 3:03 AM
  • Sean,

    I set it and run 1500 iteration with max 1500 user but it turned out there were only ~500 users created and tried to run tests again until 1500 test run!

    No idea :)

    Friday, April 5, 2013 3:21 AM
  • Hi,

    Could you share us a screen shot about your result? Where did you get the 500 users?

    As far as I know, iterations and users have nothing to do with each other, see “What is the link between the User load and the iteration in the VSTS 2008 load test?”.

    Best Regards,

    About the Virtual User Activity, see:


    Jack Zhai [MSFT]
    MSDN Community Support | Feedback to us
    Develop and promote your apps in Windows Store
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    Friday, April 5, 2013 8:58 AM
  • Hi Ben

    If you are using Web Test and if you have done parameterisation in that then you can select unique in your data access type for the added data source. You need to make sure before opting for this option that your data source contains the required number of unique users otherwise your test will terminate after all the unique users from your data source are consumed. Example you want to run it for 100 unique user but if you have only 50 unique users in your data source then it will run only 50 iterations not 100 iterations.

    The Ghost

    Thursday, October 17, 2013 11:05 AM