package de.duehl.swing.ui.colors;

import static org.junit.Assert.assertEquals;

import java.awt.Color;

import org.junit.Test;

public class NamedColorFabricTest {

    @Test
    public void createAubergine() {
        NamedColorListFabric fabric = new NamedColorListFabric();
        Color actual = fabric.getColorByName("aubergine");
        Color expected = new Color(105, 59, 88);
        assertEquals(expected, actual);
    }

    @Test
    public void createAubergineViaConstantName() {
        NamedColorListFabric fabric = new NamedColorListFabric();
        Color actual = fabric.getColorByName(NamedColorListFabric.AUBERGINE);
        Color expected = new Color(105, 59, 88);
        assertEquals(expected, actual);
    }

}
