source: josm/trunk/test/unit/org/openstreetmap/josm/gui/dialogs/ConflictDialogTest.java@ 9601

Last change on this file since 9601 was 9601, checked in by Don-vip, 8 years ago

ConflictDialog: fix Sonar/Coverity issues + add basic unit test

File size: 960 bytes
Line 
1// License: GPL. For details, see LICENSE file.
2package org.openstreetmap.josm.gui.dialogs;
3
4import static org.junit.Assert.assertEquals;
5import static org.junit.Assert.assertNotNull;
6
7import java.awt.Color;
8
9import org.junit.BeforeClass;
10import org.junit.Test;
11import org.openstreetmap.josm.JOSMFixture;
12
13/**
14 * Unit tests of {@link ConflictDialog} class.
15 */
16public class ConflictDialogTest {
17
18 /**
19 * Setup tests
20 */
21 @BeforeClass
22 public static void setUpBeforeClass() {
23 JOSMFixture.createUnitTestFixture().init(true);
24 }
25
26 /**
27 * Unit test of {@link ConflictDialog#ConflictDialog}.
28 */
29 @Test
30 public void testConflictDialog() {
31 assertNotNull(new ConflictDialog());
32 }
33
34 /**
35 * Unit test of {@link ConflictDialog#getColor} method.
36 */
37 @Test
38 public void testGetColor() {
39 assertEquals(Color.gray, ConflictDialog.getColor());
40 }
41}
Note: See TracBrowser for help on using the repository browser.