/src/test/java/com/eastrobot/doc/watermark/WatermarkProcessorTests.java

https://github.com/ekoz/kbase-doc · Java · 30 lines · 16 code · 6 blank · 8 comment · 0 complexity · be03edfb0796f6d9596eaee864606549 MD5 · raw file

  1. /*
  2. * Power by www.xiaoi.com
  3. */
  4. package com.eastrobot.doc.watermark;
  5. import java.io.File;
  6. import org.junit.Test;
  7. /**
  8. * @author <a href="mailto:eko.z@outlook.com">eko.zhan</a>
  9. * @date 2018年9月18日 上午9:49:25
  10. * @version 1.0
  11. */
  12. public class WatermarkProcessorTests {
  13. @Test
  14. public void testProcessor() throws WatermarkException {
  15. File file = new File("E:\\ConvertTester\\excel\\什么是中央处理器.xlsx");
  16. File imgFile = new File("E:\\ConvertTester\\images\\jshrss-logo.png");
  17. WatermarkProcessor.process(file, imgFile);
  18. }
  19. @Test
  20. public void testProcessorText() throws WatermarkException {
  21. File file = new File("E:\\ConvertTester\\excel\\什么是中央处理器.xlsx");
  22. WatermarkProcessor.process(file, "小i机器人");
  23. }
  24. }