< Summary

Information
Class: ValidateLib.Metadata.PropertyParsers.Column.SuppresOutputPropertyParser
Assembly: validatelib.dll
File(s): C:\skola_karlovka\RP\code\csv-validator\CSV_Validator\ValidateLib\Metadata\PropertyParsers\Column\SuppresOutputPropertyParser.cs
Line coverage
100%
Covered lines: 7
Uncovered lines: 0
Coverable lines: 7
Total lines: 25
Line coverage: 100%
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

MethodBlocks covered Blocks not covered
SuppresOutputPropertyParser(...)20
ParseProperty(...)210

File(s)

C:\skola_karlovka\RP\code\csv-validator\CSV_Validator\ValidateLib\Metadata\PropertyParsers\Column\SuppresOutputPropertyParser.cs

#LineLine coverage
 1using Newtonsoft.Json.Linq;
 2using ValidateLib.ErrorsAndWarnings.Warnings;
 3using ValidateLib.Metadata.Descriptors;
 4
 5namespace ValidateLib.Metadata.PropertyParsers.Column
 6{
 7    internal class SuppresOutputPropertyParser : PropertyParserBase<ColumnDescriptor>, IPropertyParser<ColumnDescriptor>
 8    {
 19        public SuppresOutputPropertyParser(List<Warning> warnings, ColumnDescriptor? descriptor = null) : base(warnings,
 10        {
 111        }
 12
 13        public void ParseProperty(JProperty property)
 14        {
 115            if (property.Value.Type != JTokenType.Boolean)
 16            {
 117                Warnings.Add(WarningFactory.GetAtomicPropertyBoolWrongValueWarning(property.Value, property.Name, proper
 118                Descriptor.suppresOutput = new Properties.AtomicProperties.AtomicPropertyBoolean(false);
 19            }
 20            else
 121                Descriptor.suppresOutput = new Properties.AtomicProperties.AtomicPropertyBoolean((bool)property.Value);
 22
 123        }
 24    }
 25}