zoukankan      html  css  js  c++  java
  • postman获取变量

    case 一

    http://{{variable_key}}/api/weather/city/101200101

     pre-Script

    postman.clearEnvironmentVariable("variable_key");
    postman.setEnvironmentVariable("variable_key", "t.weather.sojson.com");

    Tests

    var response = JSON.parse(responseBody);
    console.log("response:"+response);

    var status=response.status
    console.log("status:"+status);
    pm.environment.set("variable_key1", "不要说话");

    case二

    https://api.apiopen.top/searchMusic?name={{variable_key1}}

     pre-Script

     console.log(pm.environment.get("variable_key1"));

    Tests

    var response = JSON.parse(responseBody);

    var author=response.result[0].author;
    console.log("author:"+author);
     
     
     

     

    md5加密

    https://testerhome.com/topics/14400

  • 相关阅读:
    作业
    作业4
    作业1
    作业
    补交课堂作业
    补交最后一题
    第三次作业
    作业
    C语言 homework(4)
    C语言 homework (3)
  • 原文地址:https://www.cnblogs.com/mobies/p/11828057.html
Copyright © 2011-2022 走看看