|
@@ -1,4 +1,4 @@
|
|
|
-//package org.jeecg;
|
|
|
+package org.jeecg;
|
|
|
//
|
|
|
//import org.jeecg.modules.demo.mock.MockController;
|
|
|
//import org.jeecg.modules.demo.test.entity.JeecgDemo;
|
|
@@ -6,16 +6,40 @@
|
|
|
//import org.jeecg.modules.demo.test.service.IJeecgDemoService;
|
|
|
//import org.junit.Assert;
|
|
|
//import org.junit.Test;
|
|
|
-//import org.junit.runner.RunWith;
|
|
|
-//import org.springframework.boot.test.context.SpringBootTest;
|
|
|
-//import org.springframework.test.context.junit4.SpringRunner;
|
|
|
+import cn.com.ctop.common.module.entity.CtopOauthToken;
|
|
|
+import cn.com.ctop.common.module.service.ICtopOauthTokenService;
|
|
|
+import cn.com.ctop.kuaishou.modules.report.service.IKuaishouAudienceReportDailyService;
|
|
|
+import com.alibaba.fastjson.JSONArray;
|
|
|
+import org.junit.Test;
|
|
|
+import org.junit.runner.RunWith;
|
|
|
+import org.springframework.beans.factory.annotation.Autowired;
|
|
|
+import org.springframework.boot.test.context.SpringBootTest;
|
|
|
+import org.springframework.test.context.junit4.SpringRunner;
|
|
|
//
|
|
|
//import javax.annotation.Resource;
|
|
|
//import java.util.List;
|
|
|
//
|
|
|
-//@RunWith(SpringRunner.class)
|
|
|
-//@SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT,classes = JeecgSystemApplication.class)
|
|
|
-//public class SampleTest {
|
|
|
+@RunWith(SpringRunner.class)
|
|
|
+@SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT,classes = JeecgSystemApplication.class)
|
|
|
+public class SampleTest {
|
|
|
+ @Autowired
|
|
|
+ private ICtopOauthTokenService tokenService;
|
|
|
+ @Autowired
|
|
|
+ IKuaishouAudienceReportDailyService kuaishouAudienceReportDailyService;
|
|
|
+ @Test
|
|
|
+ public void haha(){
|
|
|
+ CtopOauthToken token = tokenService.getTokenByAccountId(9556431l);
|
|
|
+ JSONArray types = new JSONArray();
|
|
|
+ // province: 省级地域分布, city: 地级地域分布,gender: 性别分布,ageSegment: 年龄分布, clientId: 系统分布 businessInterestTags: 商业兴趣分布
|
|
|
+
|
|
|
+ types.add("province");
|
|
|
+ types.add("city");
|
|
|
+ types.add("gender");
|
|
|
+ types.add("ageSegment");
|
|
|
+ types.add("businessInterestTags");
|
|
|
+ types.add("clientId");
|
|
|
+ kuaishouAudienceReportDailyService.crowdAnalysisReport3(token, "2021-05-01", types, 50293820l, 216264247l, 1, 2000);
|
|
|
+ }
|
|
|
//
|
|
|
// @Resource
|
|
|
// private JeecgDemoMapper jeecgDemoMapper;
|
|
@@ -62,4 +86,4 @@
|
|
|
//// sysDataLogService.addDataLog(tableName, dataId, dataContent);
|
|
|
//// }
|
|
|
// //author:lvdandan-----date:20190315---for:添加数据日志测试----
|
|
|
-//}
|
|
|
+}
|