public void PrintToString_WhenTakeOnlySerial()
 {
     _class = new ClassWithField {
         StrField = "String"
     };
     _class.PrintToString(ser => ser.AlternativeFor <string>().TakeOnly(1)).Should().NotContain(_class.StrField)
     .And.Contain(_class.StrField[0].ToString());
 }
        public void PrintToString_WhenAlternativeCultureSerial(string culture, double height, string expectHeight)
        {
            var _class = new ClassWithField {
                DoublField = height
            };
            var result = _class.PrintToString(ser => ser.AlternativeFor <double>().Using(new CultureInfo(culture)));

            result.Should().Contain(expectHeight);
        }
        public void PrintToString_WhenTakeOnlySerialWithNullOrEmpty(string str)
        {
            _class = new ClassWithField {
                StrField = str
            };
            var result = _class.PrintToString(ser => ser.AlternativeFor <string>().TakeOnly(1));

            result.Should().Contain(nameof(_class.StrField));
        }
        public void PrintToString_WhenPersonWithArgument_ShouldContainValueAfterName()
        {
            _class = new ClassWithField {
                StrField = "Value"
            };
            var result = _class.PrintToString();

            IsValueAfterName(nameof(_class.StrField), _class.StrField, result).Should().BeTrue();
        }
 public void SetUp()
 {
     _class = new ClassWithField();
 }