Skip to content

Commit

Permalink
Adding comment about the thread safety
Browse files Browse the repository at this point in the history
  • Loading branch information
Keboo committed Oct 3, 2022
1 parent bbd7d79 commit e0562cb
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions Moq.AutoMock/AutoMocker.cs
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,7 @@ public AutoMocker(MockBehavior mockBehavior, DefaultValue defaultValue, DefaultV
/// The keys are the types used when resolving services.
/// </summary>
public IReadOnlyDictionary<Type, object?> ResolvedObjects
//NB: NonBlocking.ConcurrentDictionary GetEnumerator method returns a snapshot enumerator which is thread-safe
=> TypeMap?.ToDictionary(kvp => kvp.Key, kvp =>
{
return kvp.Value switch
Expand Down

0 comments on commit e0562cb

Please sign in to comment.