赛普拉斯:我想从JSON获取数据并将其作为参数传递给其他测试

问题描述

我有一个POST登录请求。 它返回带有“ accesstoken”的JSON。 为了执行将来的REST调用,我必须使用标头中的“ accesstoken”作为授权。

所以我创建了一个命令,例如:

synchronized

....

在测试中,我想使用返回的access_token:

// rest of the code

class Buffer {
    private int counter = 0; 
    // added synchronized keyword to let only one thread
    // be it inc or dec thread to manipulate data at a time
    public synchronized void inc() { counter++; }
    public synchronized void dec() { counter--; } 
    public int getCounter() { return counter; }
}

// rest of the code

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)