using System.Collections.Generic;
using Newtonsoft.Json.Linq;
public class OdspWebJsonDisabledTestCase
public string TestID { get; set; }
[JsonProperty(PropertyName = "TestName")]
public string TestName { get; set; }
[JsonProperty(PropertyName = "Owner")]
public string Owner { get; set; }
[JsonProperty(PropertyName = "ConfigNames")]
public List<string> ConfigNames { get; set; }
[JsonProperty(PropertyName = "Environments")]
public List<string> Environments { get; set; }
public class OdspWebJsonDisabledFile
[JsonProperty(PropertyName = "$schema")]
public IDictionary<string, JToken> DisabledTestCases { get; set; }
public OdspWebJsonDisabledFile()
this.DisabledTestCases = new Dictionary<string, JToken>();
public static void Main()
""$schema"": ""../../../tools/project-validator/src/schemas/active-tab-killswitches.schema.json"",
""b9f59395-4c91-48d5-a5b1-965998798dbd"": {
""Owner"": ""chenhui@microsoft.com"",
""ConfigNames"": [""odcspoconfig""],
""Environments"": [""global""],
""TestName"": ""COB Search""
""b9f59395-4c91-48d5-a5b1-965998798dba"": {
""Owner"": ""chenhui@microsoft.com"",
""ConfigNames"": [""odcspoconfig""],
""Environments"": [""global""],
""TestName"": ""COB Search""
""b9f59395-4c91-48d5-a5b1-965998798dbc"": {
""Owner"": ""chenhui@microsoft.com"",
""ConfigNames"": [""odcspoconfig""],
""Environments"": [""global""],
""TestName"": ""COB Search""
OdspWebJsonDisabledFile odspWebJsonDisabledFile = JsonConvert.DeserializeObject<OdspWebJsonDisabledFile>(jsonString);
string serializedStr = JsonConvert.SerializeObject(odspWebJsonDisabledFile, Formatting.Indented);
Console.WriteLine("Deserializing and then serializing results gives:");
Console.WriteLine(serializedStr);