Visual Studio Load / Performance Tests - Parameterizing REST Values ​​in a URL

I'm starting out with Visual Studio 2012, and I have been tasked with writing a few load tests that fall into REST services. Fighting because I would like to parameterize the value that is in the URL, access the CSV file as a data source.

For example, I would like the URL to be http://staging.company.com/OrderService.svc/GetOrderInfo/ {{OrderId}}

... and use the CSV file to iterate over the OrderId list.

There is a lot of information on the Internet about parameterizing values ​​in the request body, and I looked at “Linking a data source to a Web performance test” here: http://msdn.microsoft.com/en-us/library/ms404707.aspx .

Am I just missing something obvious or is there no way to do this?

Thanks.

+7
source share
1 answer

You are on the right track, but for an unclear reason, you cannot bind context parameters to a data source. Your only solution is to place the binding expression in the url:

http://staging.company.com/OrderService.svc/GetOrderInfo/{{MyDataSource.MyTestData#csv.column1}} 
+6
source

All Articles