forked from Azure/azure-sdk-for-net
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' of https://github.com/Azure/azure-sdk-for-net
- Loading branch information
Showing
4,738 changed files
with
547,760 additions
and
276,246 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
There are no files selected for viewing
Validating CODEOWNERS rules …
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
// Copyright (c) Microsoft Corporation. All rights reserved. | ||
// Licensed under the MIT License. | ||
|
||
using Azure.Test.Perf; | ||
using System; | ||
using System.Threading; | ||
using System.Threading.Tasks; | ||
|
||
namespace Azure.Sample.Perf | ||
{ | ||
// The perf framework should ignore OperationCanceledException thrown by Run/RunAsync(), but only | ||
// if the test is being cancelled. This verifies that an OperationCanceledException thrown earlier | ||
// will cause the perf framework to fail fast. | ||
// https://github.com/Azure/azure-sdk-for-net/issues/21241 | ||
|
||
public class OperationCanceledTest : PerfTest<PerfOptions> | ||
{ | ||
public OperationCanceledTest(PerfOptions options) : base(options) | ||
{ | ||
} | ||
|
||
public override void Run(CancellationToken cancellationToken) | ||
{ | ||
throw new OperationCanceledException(); | ||
} | ||
|
||
public override Task RunAsync(CancellationToken cancellationToken) | ||
{ | ||
throw new OperationCanceledException(); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.