package cn.cerc.db.jiguang;

import cn.cerc.db.core.StubHandleText;
import org.junit.Before;
import org.junit.Test;

public class JiguangPushTest {
    private static final String sound = "trade_mall.wav";
    private StubHandleText handle;

    @Before
    public void setUp() throws Exception {
        handle = new StubHandleText();
    }

    @Test
    public void test() {
        // 初始化极光推送
        JiguangPush push = new JiguangPush(handle);

        // 消息标题，仅安卓机型有效，IOS设备忽略
        push.setTitle("消息推送测试");

        // 通知栏消息内容
        push.setMessage("这是系统向您发送的测试消息，如有打扰，请您忽略，谢谢！");

        // 附加的消息id
        push.setMsgId("3707");

        // 发送给指定的设备Id
//        push.send(ClientType.Android, "n_f94e14e75bd846d1");// ly-Android
        push.send(ClientType.Android, "n_862391030069496");// ly-Android
//        push.send(ClientType.IOS, "i_59C532BB213C41D5BE3A117EB4D9FB67");// HuangRongjun-iPhone
//        push.send(ClientType.IOS, "i_77598CF689994EE3B110D6B20F1368B7", sound);// HuangRongjun-iPhone

        // 发送给指定的设备类型
        // push.send(ClientType.IOS, null);
        // push.send(ClientType.Android, null);

        // 发送给所有的用户
        // push.send();
    }

}

@@ -658,18 +658,16 @@
 %E6%8C%87%E5%AE%9A%E7%9A%84%E8%AE%BE%E5%A4%87Id%0A
-//
         
@@ -703,40 +703,47 @@
  %22n_
-f94e14e75bd846d1%22);// ly-Android
+e201ff3670a4174b%22);// itjun-xiaomi-mix2
 %0A   
@@ -805,18 +805,23 @@
 ;// 
-ly-Android
+weibo-xiaomi-5c
 %0A// 

Update JiguangPushTest.java