Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"parameters": {
"subscriptionId": "12345678-1234-1234-12345678abc",
"resourceGroupName": "exampleResourceGroup",
"factoryName": "exampleFactoryName",
"runId": "39692ed9-c722-4d33-b8e1-1f4a9deac57f",
"api-version": "2017-09-01-preview"
},
"responses": {
"200": {
"headers": {
"Date": "Mon, 02 Oct 2017 17:27:33 GMT",
"x-ms-request-id": "fd3867ea-c65c-470d-a17b-d83c8864cf90",
"X-Content-Type-Options": "nosniff",
"x-ms-ratelimit-remaining-subscription-writes": "1113",
"x-ms-correlation-request-id": "d0b45db5-c155-4991-95d9-22655c72c986"
},
"body": null
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -436,6 +436,15 @@ public void Pipelines_CreateRun()
});
}

[Fact]
public void Factories_CancelPipelineRun()
{
RunTest("Factories_CancelPipelineRun", (example, client, responseCode) =>
{
client.Factories.CancelPipelineRun(RGN(example), FN(example), new Guid().ToString());
});
}

[Fact]
public void PipelineRuns_ListByFactory()
{
Expand Down
12 changes: 10 additions & 2 deletions src/SDKs/DataFactory/DataFactory.Tests/Utils/ExampleCapture.cs
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ public void CaptureAllExamples()
EnsureResourceGroupExists();
EnsureFactoryDoesNotExist();
ServiceClientTracing.IsEnabled = true;

// Start Factories operations, leaving factory available
CaptureFactories_CreateOrUpdate(); // 200
CaptureFactories_Update(); // 200
Expand Down Expand Up @@ -95,6 +95,7 @@ public void CaptureAllExamples()
string runId = CapturePipelines_CreateRun(); // 202, ISSUE service doesn't follow long-running pattern
System.Threading.Thread.Sleep(TimeSpan.FromSeconds(120)); // Prefer to get succeeded monitoring result on first attempt even if it slows capture
DateTime afterEndTime = DateTime.UtcNow.AddMinutes(10); // allow 10 minutes for run time, monitoring latency, and clock skew
CaptureFactories_CancelRun();

CapturePipelineRuns_ListByFactory(runId, beforeStartTime, afterEndTime); // 200, waits until succeeded so ready to get logs
CapturePipelineRuns_Get(runId); // 200
Expand Down Expand Up @@ -123,7 +124,7 @@ public void CaptureAllExamples()
// Finish LinkedServices operations, deleting linked service
CaptureLinkedServices_Delete(); // 200
CaptureLinkedServices_Delete(); // 204

// Finish integration runtime operations, deleting integration runtime
CaptureIntegrationRuntimes_Delete(); // 202
CaptureIntegrationRuntimes_Delete(); // 204
Expand Down Expand Up @@ -559,6 +560,13 @@ private string CapturePipelines_CreateRun()
return rtr.RunId;
}

private void CaptureFactories_CancelRun()
{
string runId = this.CapturePipelines_CreateRun();
interceptor.CurrentExampleName = "Factories_CancelPipelineRun";
client.Factories.CancelPipelineRun(secrets.ResourceGroupName, secrets.FactoryName, runId);
}

private void CapturePipelines_Delete()
{
interceptor.CurrentExampleName = "Pipelines_Delete";
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
// <auto-generated>
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for
// license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is
// regenerated.
// </auto-generated>

namespace Microsoft.Azure.Management.DataFactory
{
using Microsoft.Azure;
using Microsoft.Azure.Management;
using Microsoft.Rest;
using Microsoft.Rest.Azure;
using Models;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
// <auto-generated>
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for
// license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is
// regenerated.
// </auto-generated>

namespace Microsoft.Azure.Management.DataFactory
{
using Microsoft.Azure;
using Microsoft.Azure.Management;
using Microsoft.Rest;
using Microsoft.Rest.Azure;
using Models;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
// <auto-generated>
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for
// license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is
// regenerated.
// </auto-generated>

namespace Microsoft.Azure.Management.DataFactory
{
using Microsoft.Azure;
using Microsoft.Azure.Management;
using Microsoft.Rest;
using Microsoft.Rest.Azure;
using Microsoft.Rest.Serialization;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
// <auto-generated>
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for
// license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is
// regenerated.
// </auto-generated>

namespace Microsoft.Azure.Management.DataFactory
{
using Microsoft.Azure;
using Microsoft.Azure.Management;
using Microsoft.Rest;
using Microsoft.Rest.Azure;
using Models;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
// <auto-generated>
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for
// license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is
// regenerated.
// </auto-generated>

namespace Microsoft.Azure.Management.DataFactory
{
using Microsoft.Azure;
using Microsoft.Azure.Management;
using Microsoft.Rest;
using Microsoft.Rest.Azure;
using Models;
Expand Down
Loading