Index: trunk/test/unit/org/openstreetmap/josm/actions/mapmode/AddNoteActionTest.java
===================================================================
--- trunk/test/unit/org/openstreetmap/josm/actions/mapmode/AddNoteActionTest.java	(revision 9944)
+++ trunk/test/unit/org/openstreetmap/josm/actions/mapmode/AddNoteActionTest.java	(revision 9944)
@@ -0,0 +1,48 @@
+// License: GPL. For details, see LICENSE file.
+package org.openstreetmap.josm.actions.mapmode;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertTrue;
+
+import java.util.Collections;
+
+import org.junit.BeforeClass;
+import org.junit.Test;
+import org.openstreetmap.josm.JOSMFixture;
+import org.openstreetmap.josm.Main;
+import org.openstreetmap.josm.data.notes.Note;
+import org.openstreetmap.josm.data.osm.DataSet;
+import org.openstreetmap.josm.data.osm.NoteData;
+import org.openstreetmap.josm.gui.layer.OsmDataLayer;
+
+/**
+ * Unit tests for class {@link AddNoteAction}.
+ */
+public class AddNoteActionTest {
+
+    /**
+     * Setup test.
+     */
+    @BeforeClass
+    public static void setUp() {
+        JOSMFixture.createUnitTestFixture().init(true);
+    }
+
+    /**
+     * Unit test of {@link AddNoteAction#enterMode} and {@link AddNoteAction#exitMode}.
+     */
+    @Test
+    public void testMode() {
+        OsmDataLayer layer = new OsmDataLayer(new DataSet(), "", null);
+        try {
+            Main.main.addLayer(layer);
+            AddNoteAction mapMode = new AddNoteAction(Main.map, new NoteData(Collections.<Note>emptyList()));
+            MapMode oldMapMode = Main.map.mapMode;
+            assertTrue(Main.map.selectMapMode(mapMode));
+            assertEquals(mapMode, Main.map.mapMode);
+            assertTrue(Main.map.selectMapMode(oldMapMode));
+        } finally {
+            Main.main.removeLayer(layer);
+        }
+    }
+}
Index: trunk/test/unit/org/openstreetmap/josm/actions/mapmode/DeleteActionTest.java
===================================================================
--- trunk/test/unit/org/openstreetmap/josm/actions/mapmode/DeleteActionTest.java	(revision 9944)
+++ trunk/test/unit/org/openstreetmap/josm/actions/mapmode/DeleteActionTest.java	(revision 9944)
@@ -0,0 +1,44 @@
+// License: GPL. For details, see LICENSE file.
+package org.openstreetmap.josm.actions.mapmode;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertTrue;
+
+import org.junit.BeforeClass;
+import org.junit.Test;
+import org.openstreetmap.josm.JOSMFixture;
+import org.openstreetmap.josm.Main;
+import org.openstreetmap.josm.data.osm.DataSet;
+import org.openstreetmap.josm.gui.layer.OsmDataLayer;
+
+/**
+ * Unit tests for class {@link DeleteAction}.
+ */
+public class DeleteActionTest {
+
+    /**
+     * Setup test.
+     */
+    @BeforeClass
+    public static void setUp() {
+        JOSMFixture.createUnitTestFixture().init(true);
+    }
+
+    /**
+     * Unit test of {@link DeleteAction#enterMode} and {@link DeleteAction#exitMode}.
+     */
+    @Test
+    public void testMode() {
+        OsmDataLayer layer = new OsmDataLayer(new DataSet(), "", null);
+        try {
+            Main.main.addLayer(layer);
+            DeleteAction mapMode = new DeleteAction(Main.map);
+            MapMode oldMapMode = Main.map.mapMode;
+            assertTrue(Main.map.selectMapMode(mapMode));
+            assertEquals(mapMode, Main.map.mapMode);
+            assertTrue(Main.map.selectMapMode(oldMapMode));
+        } finally {
+            Main.main.removeLayer(layer);
+        }
+    }
+}
Index: trunk/test/unit/org/openstreetmap/josm/actions/mapmode/ExtrudeActionTest.java
===================================================================
--- trunk/test/unit/org/openstreetmap/josm/actions/mapmode/ExtrudeActionTest.java	(revision 9944)
+++ trunk/test/unit/org/openstreetmap/josm/actions/mapmode/ExtrudeActionTest.java	(revision 9944)
@@ -0,0 +1,44 @@
+// License: GPL. For details, see LICENSE file.
+package org.openstreetmap.josm.actions.mapmode;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertTrue;
+
+import org.junit.BeforeClass;
+import org.junit.Test;
+import org.openstreetmap.josm.JOSMFixture;
+import org.openstreetmap.josm.Main;
+import org.openstreetmap.josm.data.osm.DataSet;
+import org.openstreetmap.josm.gui.layer.OsmDataLayer;
+
+/**
+ * Unit tests for class {@link ExtrudeAction}.
+ */
+public class ExtrudeActionTest {
+
+    /**
+     * Setup test.
+     */
+    @BeforeClass
+    public static void setUp() {
+        JOSMFixture.createUnitTestFixture().init(true);
+    }
+
+    /**
+     * Unit test of {@link ExtrudeAction#enterMode} and {@link ExtrudeAction#exitMode}.
+     */
+    @Test
+    public void testMode() {
+        OsmDataLayer layer = new OsmDataLayer(new DataSet(), "", null);
+        try {
+            Main.main.addLayer(layer);
+            ExtrudeAction mapMode = new ExtrudeAction(Main.map);
+            MapMode oldMapMode = Main.map.mapMode;
+            assertTrue(Main.map.selectMapMode(mapMode));
+            assertEquals(mapMode, Main.map.mapMode);
+            assertTrue(Main.map.selectMapMode(oldMapMode));
+        } finally {
+            Main.main.removeLayer(layer);
+        }
+    }
+}
Index: trunk/test/unit/org/openstreetmap/josm/actions/mapmode/ImproveWayAccuracyActionTest.java
===================================================================
--- trunk/test/unit/org/openstreetmap/josm/actions/mapmode/ImproveWayAccuracyActionTest.java	(revision 9944)
+++ trunk/test/unit/org/openstreetmap/josm/actions/mapmode/ImproveWayAccuracyActionTest.java	(revision 9944)
@@ -0,0 +1,44 @@
+// License: GPL. For details, see LICENSE file.
+package org.openstreetmap.josm.actions.mapmode;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertTrue;
+
+import org.junit.BeforeClass;
+import org.junit.Test;
+import org.openstreetmap.josm.JOSMFixture;
+import org.openstreetmap.josm.Main;
+import org.openstreetmap.josm.data.osm.DataSet;
+import org.openstreetmap.josm.gui.layer.OsmDataLayer;
+
+/**
+ * Unit tests for class {@link ImproveWayAccuracyAction}.
+ */
+public class ImproveWayAccuracyActionTest {
+
+    /**
+     * Setup test.
+     */
+    @BeforeClass
+    public static void setUp() {
+        JOSMFixture.createUnitTestFixture().init(true);
+    }
+
+    /**
+     * Unit test of {@link ImproveWayAccuracyAction#enterMode} and {@link ImproveWayAccuracyAction#exitMode}.
+     */
+    @Test
+    public void testMode() {
+        OsmDataLayer layer = new OsmDataLayer(new DataSet(), "", null);
+        try {
+            Main.main.addLayer(layer);
+            ImproveWayAccuracyAction mapMode = new ImproveWayAccuracyAction(Main.map);
+            MapMode oldMapMode = Main.map.mapMode;
+            assertTrue(Main.map.selectMapMode(mapMode));
+            assertEquals(mapMode, Main.map.mapMode);
+            assertTrue(Main.map.selectMapMode(oldMapMode));
+        } finally {
+            Main.main.removeLayer(layer);
+        }
+    }
+}
Index: trunk/test/unit/org/openstreetmap/josm/actions/mapmode/ParallelWayActionTest.java
===================================================================
--- trunk/test/unit/org/openstreetmap/josm/actions/mapmode/ParallelWayActionTest.java	(revision 9944)
+++ trunk/test/unit/org/openstreetmap/josm/actions/mapmode/ParallelWayActionTest.java	(revision 9944)
@@ -0,0 +1,44 @@
+// License: GPL. For details, see LICENSE file.
+package org.openstreetmap.josm.actions.mapmode;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertTrue;
+
+import org.junit.BeforeClass;
+import org.junit.Test;
+import org.openstreetmap.josm.JOSMFixture;
+import org.openstreetmap.josm.Main;
+import org.openstreetmap.josm.data.osm.DataSet;
+import org.openstreetmap.josm.gui.layer.OsmDataLayer;
+
+/**
+ * Unit tests for class {@link ParallelWayAction}.
+ */
+public class ParallelWayActionTest {
+
+    /**
+     * Setup test.
+     */
+    @BeforeClass
+    public static void setUp() {
+        JOSMFixture.createUnitTestFixture().init(true);
+    }
+
+    /**
+     * Unit test of {@link ParallelWayAction#enterMode} and {@link ParallelWayAction#exitMode}.
+     */
+    @Test
+    public void testMode() {
+        OsmDataLayer layer = new OsmDataLayer(new DataSet(), "", null);
+        try {
+            Main.main.addLayer(layer);
+            ParallelWayAction mapMode = new ParallelWayAction(Main.map);
+            MapMode oldMapMode = Main.map.mapMode;
+            assertTrue(Main.map.selectMapMode(mapMode));
+            assertEquals(mapMode, Main.map.mapMode);
+            assertTrue(Main.map.selectMapMode(oldMapMode));
+        } finally {
+            Main.main.removeLayer(layer);
+        }
+    }
+}
Index: trunk/test/unit/org/openstreetmap/josm/actions/mapmode/PlayHeadDragModeTest.java
===================================================================
--- trunk/test/unit/org/openstreetmap/josm/actions/mapmode/PlayHeadDragModeTest.java	(revision 9944)
+++ trunk/test/unit/org/openstreetmap/josm/actions/mapmode/PlayHeadDragModeTest.java	(revision 9944)
@@ -0,0 +1,45 @@
+// License: GPL. For details, see LICENSE file.
+package org.openstreetmap.josm.actions.mapmode;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertTrue;
+
+import org.junit.BeforeClass;
+import org.junit.Test;
+import org.openstreetmap.josm.JOSMFixture;
+import org.openstreetmap.josm.Main;
+import org.openstreetmap.josm.data.osm.DataSet;
+import org.openstreetmap.josm.gui.layer.OsmDataLayer;
+import org.openstreetmap.josm.gui.layer.markerlayer.PlayHeadMarker;
+
+/**
+ * Unit tests for class {@link PlayHeadDragMode}.
+ */
+public class PlayHeadDragModeTest {
+
+    /**
+     * Setup test.
+     */
+    @BeforeClass
+    public static void setUp() {
+        JOSMFixture.createUnitTestFixture().init(true);
+    }
+
+    /**
+     * Unit test of {@link PlayHeadDragMode#enterMode} and {@link PlayHeadDragMode#exitMode}.
+     */
+    @Test
+    public void testMode() {
+        OsmDataLayer layer = new OsmDataLayer(new DataSet(), "", null);
+        try {
+            Main.main.addLayer(layer);
+            PlayHeadDragMode mapMode = new PlayHeadDragMode(PlayHeadMarker.create());
+            MapMode oldMapMode = Main.map.mapMode;
+            assertTrue(Main.map.selectMapMode(mapMode));
+            assertEquals(mapMode, Main.map.mapMode);
+            assertTrue(Main.map.selectMapMode(oldMapMode));
+        } finally {
+            Main.main.removeLayer(layer);
+        }
+    }
+}
