qileilove

          blog已經轉移至github,大家請訪問 http://qaseven.github.io/

          軟件測試管理工具—JIRA使用初體驗

          JIRA 使用神奇的JQL查詢數據,很nice啊 !
            官網API:   https://docs.atlassian.com/jira/REST/latest/#d2e2344
            測試一下search:
          /rest/api/2/search
          request query parameters
          parametervaluedescription
          jql
          string
          a JQL query string
          startAt
          int
          the index of the first issue to return (0-based)
          maxResults
          int
          the maximum number of issues to return (defaults to 50). The maximum allowable value is dictated by the JIRA property 'jira.search.views.default.max'. If you specify a value that is higher than this number, your search results will be truncated.
          validateQuery
          boolean
          Default:true
          whether to validate the JQL query
          fields
          string
          the list of fields to return for each issue. By default, all navigable fields are returned.
          expand
          string
          A comma-separated list of the parameters to expand.
            其中jql 是一個JQL的query string。  
            測試代碼:
          string url = baseURL + "/search?jql=assignee=" +username +" and (status=1 or status=2)";
          HttpWebRequest req = WebRequest.Create(url) as HttpWebRequest;
          try
          {
          req.ContentType = "application/json";
          req.Headers.Add("Authorization", "Basic " + m_authString);
          using (HttpWebResponse resp = req.GetResponse() as HttpWebResponse)
          {
          StreamReader reader = new StreamReader(resp.GetResponseStream());
          response = reader.ReadToEnd();
          }
          }
          catch (Exception e)
          {
          response = e.Message;
          m_errorMsg = e.Message;
          return false;
          }
            也可以直接裝好以后,用url直接回車訪問上述創(chuàng)建的鏈接,會直接得到數據信息到頁面

          posted on 2014-10-30 11:00 順其自然EVO 閱讀(283) 評論(0)  編輯  收藏 所屬分類: 測試學習專欄

          <2014年10月>
          2829301234
          567891011
          12131415161718
          19202122232425
          2627282930311
          2345678

          導航

          統(tǒng)計

          常用鏈接

          留言簿(55)

          隨筆分類

          隨筆檔案

          文章分類

          文章檔案

          搜索

          最新評論

          閱讀排行榜

          評論排行榜

          主站蜘蛛池模板: 酉阳| 集贤县| 都匀市| 灵石县| 泰来县| 罗平县| 娄底市| 绥滨县| 北海市| 黎平县| 鲁甸县| 密云县| 辽源市| 灌云县| 成武县| 增城市| 荥阳市| 松原市| 浙江省| 赤城县| 彰化市| 安多县| 渝中区| 崇明县| 昆明市| 德安县| 镇坪县| 遂川县| 昌吉市| 赤壁市| 托里县| 揭东县| 河西区| 华容县| 九龙城区| 竹山县| 凭祥市| 沙田区| 阿拉善盟| 万年县| 武鸣县|