internal static string ToSerializedValue(this EnvironmentDtoType value)
        {
            switch (value)
            {
            case EnvironmentDtoType.Dev:
                return("Dev");

            case EnvironmentDtoType.Test:
                return("Test");

            case EnvironmentDtoType.Prod:
                return("Prod");
            }
            return(null);
        }
        public static void ValidateEnvironmentResponse(ICollection <Environment> environments, long?expectedId, string expectedName, string expectedDescription, EnvironmentDtoType expectedType)
        {
            Assert.IsNotNull(environments);
            Assert.AreEqual(1, environments.Count);

            var environment = environments.First();

            Assert.AreNotEqual(0, environment.Id);
            if (expectedId.HasValue)
            {
                Assert.AreEqual(expectedId.Value, environment.Id);
            }
            Assert.AreEqual(expectedName, environment.Name);
            Assert.AreEqual(expectedType, environment.Type);
            Assert.AreEqual(expectedDescription, environment.Description);
        }