Skip to content
Merged
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
Expand Up @@ -9,7 +9,6 @@
using Azure.Messaging.EventHubs.Core;
using Azure.Messaging.EventHubs.Tests;
using Azure.Storage.Blobs;
using Moq;
using NUnit.Framework;

namespace Azure.Messaging.EventHubs.Processor.Tests
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using System;
using Azure.Storage.Blobs;
using Moq;
using NUnit.Framework;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -999,11 +999,11 @@ public async Task LoadBalancingIsEnforcedWhenDistributionIsUneven()
(
EventHubConsumerClient.DefaultConsumerGroupName,
connectionString
// TODO: fix test. OwnerIdentifier is not accessible anymore.
// onInitialize: eventArgs =>
// ownedPartitionsCount.AddOrUpdate(eventArgs.Context.OwnerIdentifier, 1, (ownerId, value) => value + 1),
// onStop: eventArgs =>
// ownedPartitionsCount.AddOrUpdate(eventArgs.Context.OwnerIdentifier, 0, (ownerId, value) => value - 1)
// TODO: fix test. OwnerIdentifier is not accessible anymore.
// onInitialize: eventArgs =>
// ownedPartitionsCount.AddOrUpdate(eventArgs.Context.OwnerIdentifier, 1, (ownerId, value) => value + 1),
// onStop: eventArgs =>
// ownedPartitionsCount.AddOrUpdate(eventArgs.Context.OwnerIdentifier, 0, (ownerId, value) => value - 1)
);

eventProcessorManager.AddEventProcessors(1);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -764,7 +764,8 @@ private static async IAsyncEnumerable<PartitionEvent> MockPartitionEventEnumerab
{
for (var index = 0; index < eventCount; ++index)
{
if (cancellationToken.IsCancellationRequested) { break; }
if (cancellationToken.IsCancellationRequested)
{ break; }
await Task.Delay(25).ConfigureAwait(false);
yield return new PartitionEvent(new MockPartitionContext("fake"), new EventData(Encoding.UTF8.GetBytes($"Event { index }")));
}
Expand All @@ -781,7 +782,8 @@ private static async IAsyncEnumerable<PartitionEvent> MockEmptyPartitionEventEnu
{
for (var index = 0; index < eventCount; ++index)
{
if (cancellationToken.IsCancellationRequested) { break; }
if (cancellationToken.IsCancellationRequested)
{ break; }
await Task.Delay(25).ConfigureAwait(false);
yield return new PartitionEvent();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
// Licensed under the MIT License.

using System;
using System.ComponentModel;
using System.Globalization;
using System.Net;
using System.Security.Cryptography;
Expand Down
Loading