From 4351e71d782741143a98f86f6648acd16689165f Mon Sep 17 00:00:00 2001
From: Helius <wangdoubleone@gmail.com>
Date: Fri, 27 May 2022 19:48:02 +0800
Subject: [PATCH] Merge branch 'developer' into hive2.0
---
zq-erp/src/test/java/com/matrix/LocalCacheTest.java | 37 +++++++++++++++++++++++++++++++++++++
1 files changed, 37 insertions(+), 0 deletions(-)
diff --git a/zq-erp/src/test/java/com/matrix/LocalCacheTest.java b/zq-erp/src/test/java/com/matrix/LocalCacheTest.java
new file mode 100644
index 0000000..b91395a
--- /dev/null
+++ b/zq-erp/src/test/java/com/matrix/LocalCacheTest.java
@@ -0,0 +1,37 @@
+/**
+ * projectName: zq-erp
+ * fileName: LocalCacheTest.java
+ * packageName: com.matrix
+ * date: 2021-10-25 14:03
+ * copyright(c) 2021 http://www.hydee.cn/ Inc. All rights reserved.
+ */
+package com.matrix;
+
+import com.alibaba.fastjson.TypeReference;
+import com.matrix.system.common.bean.SysUsers;
+import com.matrix.system.common.init.LocalCache;
+import org.junit.Assert;
+import org.junit.Test;
+
+import java.io.IOException;
+
+/**
+ * @version: V1.0
+ * @author: JiangYouYao
+ * @className: LocalCacheTest
+ * @packageName: com.matrix
+ * @description: LocalCache
+ * @data: 2021-10-25 14:03
+ **/
+public class LocalCacheTest {
+
+ @Test
+ public void testNoticeTask() throws IOException, InterruptedException {
+ LocalCache.save("name","jyy",1000*3);
+ System.out.println("放入对象");
+ Assert.assertNotNull(LocalCache.get("name",new TypeReference<SysUsers>(){}));
+ Thread.sleep(1000*5);
+ Assert.assertNull(LocalCache.get("name",new TypeReference<SysUsers>(){}));
+ }
+
+}
\ No newline at end of file
--
Gitblit v1.9.1