You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
21 lines
559 B
21 lines
559 B
package com.fanruan.api.util; |
|
|
|
import com.fanruan.api.report.PaintKit; |
|
import com.fr.base.Style; |
|
import com.fr.plugin.present.fun.StarPainter; |
|
import org.junit.Assert; |
|
import org.junit.Test; |
|
|
|
import java.awt.*; |
|
|
|
public class PaintKitTest { |
|
|
|
@Test |
|
public void value2Image() { |
|
StarPainter star = new StarPainter(1); |
|
Style style = Style.getInstance(); |
|
Image image = PaintKit.value2Image(star, 1, style, 30, 50); |
|
Assert.assertEquals(30, image.getWidth(null)); |
|
Assert.assertEquals(50, image.getHeight(null)); |
|
} |
|
} |