< Summary - CoreWCF Coverage — PR #1766

Information
Class: CoreWCF.Dispatcher.HelpOperationInvoker
Assembly: CoreWCF.WebHttp
File(s): /home/runner/work/CoreWCF/CoreWCF/src/CoreWCF.WebHttp/src/CoreWCF/Dispatcher/HelpOperationInvoker.cs
Line coverage
0%
Covered lines: 0
Uncovered lines: 7
Coverable lines: 7
Total lines: 33
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%
AllocateInputs()100%110%
InvokeAsync(...)100%110%

File(s)

/home/runner/work/CoreWCF/CoreWCF/src/CoreWCF.WebHttp/src/CoreWCF/Dispatcher/HelpOperationInvoker.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.Threading.Tasks;
 5using CoreWCF.Web;
 6
 7namespace CoreWCF.Dispatcher
 8{
 9    internal class HelpOperationInvoker : IOperationInvoker
 10    {
 11        private readonly HelpPage _helpPage;
 12
 13        public const string OperationName = "HelpPageInvoke";
 14
 015        public HelpOperationInvoker(HelpPage helpPage)
 16        {
 017            _helpPage = helpPage;
 018        }
 19
 20        public object[] AllocateInputs()
 21        {
 022            return new object[] { null };
 23        }
 24
 25        public ValueTask<(object returnValue, object[] outputs)> InvokeAsync(object instance, object[] inputs)
 26        {
 027            UriTemplateMatch match = (UriTemplateMatch)OperationContext.Current.IncomingMessageProperties[IncomingWebReq
 028            return new ValueTask<(object, object[])>((_helpPage.Invoke(match), null));
 29        }
 30
 031        public bool IsSynchronous => true;
 32    }
 33}