From b387d7ff6a5859fe74b5fa7b4c785a0def7823c4 Mon Sep 17 00:00:00 2001 From: Jiaju Zhuang Date: Thu, 16 Sep 2021 19:23:36 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=90=88=E5=B9=B6=E5=BC=82?= =?UTF-8?q?=E5=B8=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../easyexcel/test/core/style/StyleDataTest.java | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/src/test/java/com/alibaba/easyexcel/test/core/style/StyleDataTest.java b/src/test/java/com/alibaba/easyexcel/test/core/style/StyleDataTest.java index c9a07d18..ceb571db 100644 --- a/src/test/java/com/alibaba/easyexcel/test/core/style/StyleDataTest.java +++ b/src/test/java/com/alibaba/easyexcel/test/core/style/StyleDataTest.java @@ -40,13 +40,11 @@ public class StyleDataTest { private static File file07; private static File file03; - private static File file02_07; + @BeforeClass public static void init() { file07 = TestFileUtil.createNewFile("style07.xlsx"); file03 = TestFileUtil.createNewFile("style03.xls"); - file02_07 = TestFileUtil.createNewFile("style02_07.xlsx"); - file03 = TestFileUtil.createNewFile("style03.csv"); } @Test @@ -119,7 +117,7 @@ public class StyleDataTest { .doWrite(data()); } @Test - public void t03AbstractVerticalCellStyleStrategy02() { + public void t04AbstractVerticalCellStyleStrategy02() { final StyleProperty styleProperty = StyleProperty.build(StyleData.class.getAnnotation(HeadStyle.class)); final FontProperty fontProperty = FontProperty.build(StyleData.class.getAnnotation(HeadFontStyle.class)); AbstractVerticalCellStyleStrategy verticalCellStyleStrategy = new AbstractVerticalCellStyleStrategy() { @@ -154,11 +152,12 @@ public class StyleDataTest { return writeCellStyle; } }; - EasyExcel.write(file02_07, StyleData.class).registerWriteHandler(verticalCellStyleStrategy).sheet() + EasyExcel.write(file07, StyleData.class).registerWriteHandler(verticalCellStyleStrategy).sheet() .doWrite(data()); } + @Test - public void t04LoopMergeStrategy() { + public void t05LoopMergeStrategy() { EasyExcel.write(file07, StyleData.class).sheet().registerWriteHandler(new LoopMergeStrategy(2, 1)) .doWrite(data10()); }