From 7e6bbd05a75b07cb0717812d0b51aad128361012 Mon Sep 17 00:00:00 2001
From: Helius <wangdoubleone@gmail.com>
Date: Thu, 19 May 2022 18:43:42 +0800
Subject: [PATCH] fix some problem

---
 src/test/java/cc/mrbird/febs/AgentTest.java |   33 +++++++++++++++++++++++++++++++--
 1 files changed, 31 insertions(+), 2 deletions(-)

diff --git a/src/test/java/cc/mrbird/febs/AgentTest.java b/src/test/java/cc/mrbird/febs/AgentTest.java
index b9ad05c..6f86be6 100644
--- a/src/test/java/cc/mrbird/febs/AgentTest.java
+++ b/src/test/java/cc/mrbird/febs/AgentTest.java
@@ -4,7 +4,10 @@
 import cc.mrbird.febs.mall.dto.AgentLevelUpdateDto;
 import cc.mrbird.febs.mall.entity.AgentInfo;
 import cc.mrbird.febs.mall.entity.DataDictionaryCustom;
+import cc.mrbird.febs.mall.entity.MallGoodsStyle;
 import cc.mrbird.febs.mall.mapper.DataDictionaryCustomMapper;
+import cc.mrbird.febs.mall.mapper.MallGoodsStyleMapper;
+import cc.mrbird.febs.mall.quartz.ProfitJob;
 import cc.mrbird.febs.mall.service.IAgentService;
 import cc.mrbird.febs.rabbit.producter.AgentProducer;
 import com.alibaba.fastjson.JSONObject;
@@ -16,6 +19,7 @@
 
 import java.math.BigDecimal;
 import java.math.RoundingMode;
+import java.util.List;
 
 /**
  * @author wzy
@@ -33,6 +37,15 @@
 
     @Autowired
     private IAgentService agentService;
+
+    @Autowired
+    private MallGoodsStyleMapper mallGoodsStyleMapper;
+
+    @Test
+    public void skusTest() {
+        List<MallGoodsStyle> mallGoodsStyles = mallGoodsStyleMapper.selectByGoodsId(1L);
+        System.out.println(mallGoodsStyles);
+    }
 
     @Test
     public void agentTest() {
@@ -99,9 +112,17 @@
     @Test
     public void autoLevelUp() {
         // agentService.autoUpAgentLevel(3L);
-        agentProducer.sendAutoLevelUpMsg(5L);
+//        agentProducer.sendAutoLevelUpMsg(5L);
 
-//        agentProducer.sendReturnMoneyMsg(24L);
+        agentProducer.sendReturnMoneyMsg(2L);
+    }
+
+    @Test
+    public void returnMoney() {
+        // agentService.autoUpAgentLevel(3L);
+//        agentProducer.sendAutoLevelUpMsg(5L);
+//        agentProducer.sendReturnMoneyMsg(52L);
+        agentService.returnMoneyToAgent(52L);
     }
 
     @Test
@@ -111,4 +132,12 @@
         System.out.println(aa.setScale(2, RoundingMode.DOWN));
         System.out.println(aa.setScale(2, RoundingMode.UP));
     }
+
+    @Autowired
+    private ProfitJob profitJob;
+
+    @Test
+    public void profitJobTest() {
+        profitJob.profitJob();
+    }
 }

--
Gitblit v1.9.1