We are updating the Visual Studio Team Services Build Steps and thought these topics would be of interest:
https://msdn.microsoft.com/en-us/Library/vs/alm/Build/steps/index.
If you want to create your own Build Task check out my post here:
******************************
Cloud Load Test Build Task
Use Visual Studio Cloud-based Load Test to understand, test and validate your Applications performance.
Cloud-based Load Test task can be used to trigger a load test on the Visual Studio Online Cloud-based Load Test Service. The Cloud-based Load Test Service can be used for performance and load testing of your application by generating load from Azure. If you are new to Cloud-based Load Testing then the following links will help you:
- Cloud-based Load Testing with Visual Studio Online
- Introduction to Cloud-based Load Testing with VSO
Demands
The build agent must have the following capabilities:
- MSBuild
- Azure Power shell
For more information and the source code to this task please see: https://github.com/Microsoft/vso-agent-tasks/tree/master/Tasks/RunLoadTest
Arguments
Argument | Description |
Registered Connection |
Generic Service End point is a reference to the Visual Studio Team Services Account you will be running the Load Test from and publishing the results to. See <need link to service endpoint reference or point to this in the short term this http://roadtoalm.com/2015/07/22/using-personal-access-tokens-to-access-visual-studio-online/>
|
Test Settings File | This is the path where this task looks for the files required for the load test – load test file, test settings file, any deployment items and setup/clean-up scripts . You can pick the path and the task will do a recursive search starting at that path for your files. |
Load test files folder |
Provide the folder path to the Load Test project in this step. This is the path where this task looks for the files required for the load test – load test file, test settings file, any deployment items and setup/clean-up scripts . You can pick the path and the task will do a recursive search starting at that path for your files. |
Load test file | You also have to specify the name of the load test file (xyz.loadtest) that is to be executed as part of this task. You may have more than one load test file to perhaps cater to the various deployment environments that you deploy your App to. So pick the right one. Once these are provided, we have all the data to trigger a load test. |
Number of permissible threshold violations | Optionally if your load test is already setup with threshold violations (Learn more about threshold violations), then you can specify the number of critical violations to wait for before the load test should be deemed unsuccessful, in which case, the load test would then be aborted and the load test task would be marked as failed. |
Control Options | |
Enabled | Set whether this task runs as part of the build |
Continue On Error |
Sets if the build continues on error |
Always Run |
Sets this task to always run, even if the build has already failed |
Example
Scheduling Load Test Execution
More Information
In your Visual Studio Online account, under the ‘Build’ hub, you can create new Build definitions that can include either of the two Cloud-based load test task templates (for guidance on how to create a Build definition, go here):
- For help on the "Cloud-based Web Performance Test" go here.
- For "Cloud-based Load test" read on.
To be successful with this task, you should have already created a load test project with Visual Studio Ultimate IDE with the required web performance tests(Get started) and configured the load test appropriately. This task simply takes an already created load test as input and executes it via the Service.
To use this task, do the following:
1. For "Registered Connection":
Select an available connection from the drop down. The selected connection must be for the Visual Studio Online account that you want to use for the load test. If you’re unsure or don’t have a connection to select, click on "Manage" to see what the available connections are or to create a new one. You need to be a Project administrator with "Edit Project-level Information" privilege or can ask your administrator to create a connection for you. The connection type to select is "Generic". This is what you will encounter if don’t have the required permissions:
Pick the connection you’d like to use and move on to step 2.
2. You now need to supply the path to the Load Test settings file in your load test project. You may have more than one test settings file for your Load test, so pick the one to be used for this task. It might be configured with setup and clean scripts (Learn more) that might be essential to the load test.
3. Provide the folder path to the Load Test project in this step. This is the path where this task looks for the files required for the load test – load test file, test settings file, any deployment items and setup/clean-up scripts . You can pick the path and the task will do a recursive search starting at that path for your files.
4. You also have to specify the name of the load test file (xyz.loadtest) that is to be executed as part of this task. You may have more than one load test file to perhaps cater to the various deployment environments that you deploy your App to. So pick the right one. Once these are provided, we have all the data to trigger a load test.
5. Optionally if your load test is already setup with threshold violations (Learn more about threshold violations), then you can specify the number of critical violations to wait for before the load test should be deemed unsuccessful, in which case, the load test would then be aborted and the load test task would be marked as failed.
6. You can now save the task and then queue a build.
For generic information on Load testing you can look up these additional resources.
If you have feedback for us – for this task or for any other feature, please add them here.
There is also a similar task:
Cloud-based Web Performance Test
Runs the quick web performance test in cloud, with Visual Studio Team Services.
Cloud Load Test Build Task
Use [Visual Studio Cloud-based Load Test][3] to understand, test and validate your Applications performance.
Cloud-based Load Test task can be used to generate load against a URL using the Visual Studio Team Services Cloud-based Load Test Service. The Cloud-based Load Test Service can be used for performance and load testing of your application by generating load from Azure. If you are new to Cloud-based Load Testing then the following links will help you: •Cloud-based Load Testing with Visual Studio Online https://www.visualstudio.com/features/vso-cloud-load-testing-vs
•Introduction to Cloud-based Load Testing with VSO https://www.visualstudio.com/en-us/get-started/test/load-test-your-app-vs
Demands
The build agent must have the following capabilities:
- MSBuild
- Azure Power shell
For more information and the source code to this task please see:
Arguments
Argument
Description
Registered Connection
Generic Service End point is a reference to the Visual Studio Team Services Account you will be running the Load Test from and publishing the results to.
Website URL
The URL of the application that you’d like to load test
Test Name
The name for this load test. This name will be used to identify this load test when you look up your load test runs in the Visual Studio for reporting and comparing with other runs.
UserLoad
The number of users that will be used for this load test. This is the number of concurrent users that you want to simulate in this load test.
Run Duration
The duration you’d like this load test to run for.
Load Location
The Location from where you want the load to be generated. You can pick from Azure locations around the world. Select ‘Default’ if you want the load to be generated from the default location associated with your Visual Studio Online account.
Example
Please see: "Scheduling Load Test Execution" http://blogs.msdn.com/b/visualstudioalm/archive/2015/11/23/scheduling-load-test-execution.aspx
More Information
To get started using this task, in your Visual Studio Team Services account, under the ‘Build’ hub, you can create new Build definitions that can include either of the two Cloud-based load test task templates (for guidance on how to create a Build definition please see: https://msdn.microsoft.com/Library/vs/alm/Build/vs/define-build ):
- For help on the "Cloud-based Web Performance Test" please see: https://msdn.microsoft.com/en-us/Library/vs/alm/Build/steps/index
To use this task you will need to have already created and checked into the team project a load test created with Visual Studio Enterprise (for more information on this please see: https://www.visualstudio.com/get-started/load-test-your-app-vs). This task automates the process of running the load test as part of a build or release.
To use this task you will need a "Registered Connection" to your Visual Studio Team Services Account. The selected connection must be for the Visual Studio Online account that you want to use for the load test. If you’re unsure or don’t have a connection to select, click on "Manage" to see what the available connections are or to create a new one. You need to be a Project administrator with "Edit Project-level Information" privilege or can ask your administrator to create a connection for you. The connection type that you to select is "Generic".
For generic information on Load testing you can look up these https://aka.ms/loadtestkb.
0 comments