< Summary

Line coverage
0%
Covered lines: 0
Uncovered lines: 4
Coverable lines: 4
Total lines: 27
Line coverage: 0%
Branch coverage
N/A
Covered branches: 0
Total branches: 0
Branch coverage: N/A
Method coverage

Feature is only available for sponsors

Upgrade to PRO version

Metrics

MethodBranch coverage Cyclomatic complexity NPath complexity Sequence coverage
.ctor()100%110%
ConfigureJsonTypeInfoUsingReflection(...)100%110%

File(s)

https://raw.githubusercontent.com/dotnet/runtime/811a7eabb75c42db53440e8ba3f60c07511cfd1f/src/libraries/System.Text.Json/src/System/Text/Json/Serialization/Converters/Collection/StackOrQueueConverterWithReflection.cs

#LineLine coverage
 1// Licensed to the .NET Foundation under one or more agreements.
 2// The .NET Foundation licenses this file to you under the MIT license.
 3
 4using System.Collections;
 5using System.Diagnostics;
 6using System.Diagnostics.CodeAnalysis;
 7using System.Text.Json.Serialization.Metadata;
 8
 9namespace System.Text.Json.Serialization.Converters
 10{
 11    internal sealed class StackOrQueueConverterWithReflection<TCollection>
 12        : StackOrQueueConverter<TCollection>
 13        where TCollection : IEnumerable
 14    {
 15        [RequiresUnreferencedCode(JsonSerializer.SerializationUnreferencedCodeMessage)]
 16        [RequiresDynamicCode(JsonSerializer.SerializationRequiresDynamicCodeMessage)]
 017        public StackOrQueueConverterWithReflection() { }
 18
 19        [RequiresUnreferencedCode(JsonSerializer.SerializationUnreferencedCodeMessage)]
 20        [RequiresDynamicCode(JsonSerializer.SerializationRequiresDynamicCodeMessage)]
 21        internal override void ConfigureJsonTypeInfoUsingReflection(JsonTypeInfo jsonTypeInfo, JsonSerializerOptions opt
 022        {
 023            jsonTypeInfo.AddMethodDelegate = DefaultJsonTypeInfoResolver.MemberAccessor.CreateAddMethodDelegate<TCollect
 024        }
 25    }
 26}
 27