/// <summary>
 /// Deletes a deployment from the deployment history.
 /// </summary>
 /// <remarks>
 /// A template deployment that is currently running cannot be deleted. Deleting
 /// a template deployment removes the associated deployment operations.
 /// Deleting a template deployment does not affect the state of the resource
 /// group. This is an asynchronous operation that returns a status of 202 until
 /// the template deployment is successfully deleted. The Location response
 /// header contains the URI that is used to obtain the status of the process.
 /// While the process is running, a call to the URI in the Location header
 /// returns a status of 202. When the process finishes, the URI in the Location
 /// header returns a status of 204 on success. If the asynchronous request
 /// failed, the URI in the Location header returns an error-level status code.
 /// </remarks>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group with the deployment to delete. The name is
 /// case insensitive.
 /// </param>
 /// <param name='deploymentName'>
 /// The name of the deployment to delete.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task DeleteAsync(this IDeploymentsOperations operations, string resourceGroupName, string deploymentName, CancellationToken cancellationToken = default(CancellationToken))
 {
     (await operations.DeleteWithHttpMessagesAsync(resourceGroupName, deploymentName, null, cancellationToken).ConfigureAwait(false)).Dispose();
 }