Package com.renren.api.client.services

Source Code of com.renren.api.client.services.AdminServiceTest

package com.renren.api.client.services;

import junit.framework.Assert;

import org.json.simple.JSONObject;
import org.junit.Test;

import com.renren.api.client.AbstractServiceTest;
import com.renren.api.client.param.impl.AccessToken;

/**
* @author 李勇(yong.li@opi-corp.com) 2011-2-18
*/
public class AdminServiceTest extends AbstractServiceTest {

    @Test
    public void getAllocation() {
        JSONObject obj = this.getRenrenApiClient().getAdminService().getAllocation(new AccessToken(this.getAccessToken()));
        int i = Integer.parseInt(obj.get("notifications_per_day").toString());
        Assert.assertTrue(i > -1);
        i = Integer.parseInt(obj.get("requests_per_day").toString());
        Assert.assertTrue(i > -1);
    }

}
TOP

Related Classes of com.renren.api.client.services.AdminServiceTest

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.