コード例 #1
0
ファイル: Step.cs プロジェクト: BedeGaming/testrail-client
 /// <summary>parses json into a step</summary>
 /// <param name="json">json to parse</param>
 /// <returns>step corresponding to the json</returns>
 public static Step Parse(JObject json)
 {
     Step s = new Step();
     s.Description = (string)json["content"];
     s.Expected = (string)json["expected"];
     s.Actual = (string)json["actual"];
     s.Status = (null != (int?)json["status_id"]) ? (ResultStatus)((int)json["status_id"]) : (ResultStatus?)null;
     return s;
 }
コード例 #2
0
ファイル: Step.cs プロジェクト: zimarrio/testrail-client
 /// <summary>parses json into a step</summary>
 /// <param name="json">json to parse</param>
 /// <returns>step corresponding to the json</returns>
 public static Step Parse(JObject json)
 {
     var s = new Step
     {
         JsonFromResponse = json,
         Description = (string)json["content"],
         Expected = (string)json["expected"],
         Actual = (string)json["actual"],
         Status = (null != (int?)json["status_id"]) ? (ResultStatus)((int)json["status_id"]) : (ResultStatus?)null,
     };
     return s;
 }