@@ -0,0 +1,1747 @@
+package jButtonDecorator.decorator;%0A%0Aimport org.junit.After;%0Aimport org.junit.Before;%0Aimport org.junit.Test;%0A%0Aimport javax.swing.*;%0Aimport javax.swing.border.MatteBorder;%0Aimport java.awt.*;%0A%0Aimport static junit.framework.Assert.assertEquals;%0Aimport static junit.framework.Assert.assertNotNull;%0Aimport static junit.framework.TestCase.assertTrue;%0A%0A/**%0A * Created by vicboma on 15/10/15.%0A */%0Apublic class MatteBorderDecoratorTest %7B%0A%0A    private MatteBorderDecorator matteBorderDecorator;%0A    private JButton button;%0A%0A    @Before%0A    public void setUp() throws Exception %7B%0A        createInstance();%0A    %7D%0A%0A    @After%0A    public void tearDown() throws Exception %7B%0A        matteBorderDecorator = null;%0A    %7D%0A%0A    @Test%0A    public void testCreate() throws Exception %7B%0A        assertNotNull(%22Is null%22, matteBorderDecorator);%0A        assertTrue(%22Not same%22, matteBorderDecorator.getClass() == MatteBorderDecorator.class);%0A    %7D%0A%0A    @Test%0A    public void testBorder() throws Exception %7B%0A        final int top = 9;%0A        final int left = 3;%0A        final int bottom = 1;%0A        final int right = 6;%0A        final Color matteColor = new Color(174, 2, 126);%0A%0A        matteBorderDecorator.border(top, left, bottom, right, matteColor);%0A        final MatteBorder matte = new MatteBorder(top, left, bottom, right, matteColor);%0A%0A        assertEquals(button.getBorder().getClass(), matte.getClass());%0A        final MatteBorder border = (MatteBorder) button.getBorder();%0A        assertEquals(border.getBorderInsets(), matte.getBorderInsets());%0A        assertEquals(border.getMatteColor(), matte.getMatteColor());%0A    %7D%0A%0A    private void createInstance() %7B%0A        button = new JButton();%0A        matteBorderDecorator = MatteBorderDecorator.create(button);%0A    %7D%0A%0A%7D

add matter border test