Esempio n. 1
0
        public void EnumSerializerIsValid()
        {
            EnumConverter <HttpStatusCode> converter = new EnumConverter <HttpStatusCode>();
            HttpStatusCode code          = HttpStatusCode.NotFound;
            StringBuilder  stringBuilder = new StringBuilder();

            converter.AppendToStringBuilder(stringBuilder, CultureInfo.InvariantCulture, code, null, ',');
            string serialized = stringBuilder.ToString();

            serialized.Should().Be("NotFound");
        }