Index: trunk/test/unit/org/openstreetmap/josm/gui/layer/markerlayer/MarkerLayerTest.java
===================================================================
--- trunk/test/unit/org/openstreetmap/josm/gui/layer/markerlayer/MarkerLayerTest.java	(revision 10050)
+++ trunk/test/unit/org/openstreetmap/josm/gui/layer/markerlayer/MarkerLayerTest.java	(revision 10050)
@@ -0,0 +1,67 @@
+// License: GPL. For details, see LICENSE file.
+package org.openstreetmap.josm.gui.layer.markerlayer;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertTrue;
+
+import java.awt.Color;
+import java.util.Arrays;
+
+import org.junit.BeforeClass;
+import org.junit.Test;
+import org.openstreetmap.josm.JOSMFixture;
+import org.openstreetmap.josm.Main;
+import org.openstreetmap.josm.data.coor.LatLon;
+import org.openstreetmap.josm.data.gpx.GpxConstants;
+import org.openstreetmap.josm.data.gpx.GpxData;
+import org.openstreetmap.josm.data.gpx.GpxLink;
+import org.openstreetmap.josm.data.gpx.WayPoint;
+
+/**
+ * Unit tests of {@link MarkerLayer} class.
+ */
+public class MarkerLayerTest {
+
+    /**
+     * Setup tests
+     */
+    @BeforeClass
+    public static void setUpBeforeClass() {
+        JOSMFixture.createUnitTestFixture().init(true);
+        Main.pref.put("marker.traceaudio", true);
+    }
+
+    /**
+     * Unit test of {@link MarkerLayer#MarkerLayer}.
+     */
+    @Test
+    public void testMarkerLayer()  {
+        assertEquals(Color.magenta, MarkerLayer.getGenericColor());
+        MarkerLayer layer = new MarkerLayer(new GpxData(), "foo", null, null);
+
+        assertEquals("foo", layer.getName());
+        assertEquals(Color.magenta, layer.getColor(false));
+        assertNotNull(layer.getIcon());
+        assertEquals("0 markers", layer.getToolTipText());
+        assertEquals("<html>foo consists of 0 markers</html>", layer.getInfoComponent());
+        assertTrue(layer.getMenuEntries().length > 10);
+
+        GpxData gpx = new GpxData();
+        WayPoint wpt = new WayPoint(LatLon.ZERO);
+        wpt.attr.put(GpxConstants.META_LINKS, Arrays.asList(new GpxLink("https://josm.openstreetmap.de")));
+        wpt.addExtension("offset", "1.0");
+        gpx.waypoints.add(wpt);
+        wpt = new WayPoint(LatLon.ZERO);
+        wpt.addExtension("offset", "NaN");
+        gpx.waypoints.add(wpt);
+        layer = new MarkerLayer(gpx, "bar", null, null);
+
+        assertEquals("bar", layer.getName());
+        assertEquals(Color.magenta, layer.getColor(false));
+        assertNotNull(layer.getIcon());
+        assertEquals("3 markers", layer.getToolTipText());
+        assertEquals("<html>bar consists of 3 markers</html>", layer.getInfoComponent());
+        assertTrue(layer.getMenuEntries().length > 10);
+    }
+}
Index: trunk/test/unit/org/openstreetmap/josm/plugins/PluginDownloadExceptionTest.java
===================================================================
--- trunk/test/unit/org/openstreetmap/josm/plugins/PluginDownloadExceptionTest.java	(revision 10050)
+++ trunk/test/unit/org/openstreetmap/josm/plugins/PluginDownloadExceptionTest.java	(revision 10050)
@@ -0,0 +1,37 @@
+// License: GPL. For details, see LICENSE file.
+package org.openstreetmap.josm.plugins;
+
+import static org.junit.Assert.assertEquals;
+
+import org.junit.BeforeClass;
+import org.junit.Test;
+import org.openstreetmap.josm.JOSMFixture;
+
+/**
+ * Unit tests of {@link PluginDownloadException} class.
+ */
+public class PluginDownloadExceptionTest {
+
+    /**
+     * Setup test.
+     */
+    @BeforeClass
+    public static void setUp() {
+        JOSMFixture.createUnitTestFixture().init();
+    }
+
+    /**
+     * Unit test of {@link PluginDownloadException#PluginDownloadException}.
+     */
+    @Test
+    public void testPluginDownloadException() {
+        PluginDownloadException ex = new PluginDownloadException("foo");
+        assertEquals("foo", ex.getMessage());
+        NullPointerException npe = new NullPointerException();
+        ex = new PluginDownloadException(npe);
+        assertEquals(npe, ex.getCause());
+        ex = new PluginDownloadException("bar", npe);
+        assertEquals("bar", ex.getMessage());
+        assertEquals(npe, ex.getCause());
+    }
+}
Index: trunk/test/unit/org/openstreetmap/josm/plugins/PluginExceptionTest.java
===================================================================
--- trunk/test/unit/org/openstreetmap/josm/plugins/PluginExceptionTest.java	(revision 10050)
+++ trunk/test/unit/org/openstreetmap/josm/plugins/PluginExceptionTest.java	(revision 10050)
@@ -0,0 +1,38 @@
+// License: GPL. For details, see LICENSE file.
+package org.openstreetmap.josm.plugins;
+
+import static org.junit.Assert.assertEquals;
+
+import org.junit.BeforeClass;
+import org.junit.Test;
+import org.openstreetmap.josm.JOSMFixture;
+
+/**
+ * Unit tests of {@link PluginException} class.
+ */
+public class PluginExceptionTest {
+
+    /**
+     * Setup test.
+     */
+    @BeforeClass
+    public static void setUp() {
+        JOSMFixture.createUnitTestFixture().init();
+    }
+
+    /**
+     * Unit test of {@link PluginException#PluginException}.
+     */
+    @Test
+    public void testPluginDownloadException() {
+        PluginException ex = new PluginException("foo");
+        assertEquals("foo", ex.getMessage());
+        NullPointerException npe = new NullPointerException();
+        ex = new PluginException("bar", npe);
+        assertEquals("An error occurred in plugin bar", ex.getMessage());
+        assertEquals(npe, ex.getCause());
+        ex = new PluginException(null, "foobar", npe);
+        assertEquals("An error occurred in plugin foobar", ex.getMessage());
+        assertEquals(npe, ex.getCause());
+    }
+}
Index: trunk/test/unit/org/openstreetmap/josm/plugins/PluginListParseExceptionTest.java
===================================================================
--- trunk/test/unit/org/openstreetmap/josm/plugins/PluginListParseExceptionTest.java	(revision 10050)
+++ trunk/test/unit/org/openstreetmap/josm/plugins/PluginListParseExceptionTest.java	(revision 10050)
@@ -0,0 +1,35 @@
+// License: GPL. For details, see LICENSE file.
+package org.openstreetmap.josm.plugins;
+
+import static org.junit.Assert.assertEquals;
+
+import org.junit.BeforeClass;
+import org.junit.Test;
+import org.openstreetmap.josm.JOSMFixture;
+
+/**
+ * Unit tests of {@link PluginListParseException} class.
+ */
+public class PluginListParseExceptionTest {
+
+    /**
+     * Setup test.
+     */
+    @BeforeClass
+    public static void setUp() {
+        JOSMFixture.createUnitTestFixture().init();
+    }
+
+    /**
+     * Unit test of {@link PluginListParseException#PluginListParseException}.
+     */
+    @Test
+    public void testPluginListParseException() {
+        NullPointerException npe = new NullPointerException();
+        PluginListParseException ex = new PluginListParseException(npe);
+        assertEquals(npe, ex.getCause());
+        ex = new PluginListParseException("bar", npe);
+        assertEquals("bar", ex.getMessage());
+        assertEquals(npe, ex.getCause());
+    }
+}
