Changeset 15455 in josm


Ignore:
Timestamp:
2019-10-12T22:12:57+02:00 (4 months ago)
Author:
Don-vip
Message:

see #18219, see #18216 - update unit tests

Location:
trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/actions/AbstractMergeAction.java

    r15450 r15455  
    124124     * @param targetLayers list of candidate target layers.
    125125     * @return the chosen layer
    126      * @deprecated
     126     * @deprecated to be removed
    127127     */
    128128    @Deprecated
     
    137137     * @param checkboxDefault whether the checkbox is ticked by default
    138138     * @return The {@link TargetLayerDialogResult} containing the chosen target layer and the state of the checkbox
    139      * @deprecated
     139     * @deprecated to be removed
    140140     */
    141141    @Deprecated
  • trunk/test/unit/org/openstreetmap/josm/actions/MergeLayerActionTest.java

    r14332 r15455  
    11// License: GPL. For details, see LICENSE file.
    22package org.openstreetmap.josm.actions;
     3
     4import static org.junit.Assert.assertEquals;
     5import static org.junit.Assert.assertNull;
    36
    47import javax.swing.JLabel;
    58import javax.swing.JPanel;
    69
    7 import static org.junit.Assert.assertEquals;
    8 import static org.junit.Assert.assertNull;
    9 
    1010import org.junit.Before;
    1111import org.junit.Rule;
    1212import org.junit.Test;
     13import org.openstreetmap.josm.TestUtils;
    1314import org.openstreetmap.josm.data.osm.DataSet;
    1415import org.openstreetmap.josm.gui.ExtendedDialog;
     
    1718import org.openstreetmap.josm.gui.layer.OsmDataLayer;
    1819import org.openstreetmap.josm.gui.widgets.JosmComboBox;
    19 import org.openstreetmap.josm.TestUtils;
    2020import org.openstreetmap.josm.testutils.JOSMTestRules;
    2121import org.openstreetmap.josm.testutils.mockers.ExtendedDialogMocker;
     
    3636    @Rule
    3737    @SuppressFBWarnings(value = "URF_UNREAD_PUBLIC_OR_PROTECTED_FIELD")
    38     public JOSMTestRules test = new JOSMTestRules().main();
     38    public JOSMTestRules test = new JOSMTestRules().main().projection();
    3939
    4040    /**
     
    108108        TestUtils.assumeWorkingJMockit();
    109109        final MergeLayerExtendedDialogMocker edMocker = new MergeLayerExtendedDialogMocker();
    110         edMocker.getMockResultMap().put("Please select the target layer.", "Merge");
     110        edMocker.getMockResultMap().put("Please select the target layer.", "Merge layer");
    111111
    112112        OsmDataLayer layer1 = new OsmDataLayer(new DataSet(), "1", null);
  • trunk/test/unit/org/openstreetmap/josm/data/validation/tests/RelationCheckerTest.java

    r14990 r15455  
    137137
    138138        List<TestError> errors = testRelation(r);
    139         assertEquals(1, errors.size());
    140         assertEquals("Role of relation member does not match template expression 'power' in preset Power Route", errors.get(0).getDescription());
     139        assertEquals(2, errors.size());
     140        assertEquals("Role 'line' missing", errors.get(0).getDescription());
     141        assertEquals("Empty role found when expecting one of 'line/substation'", errors.get(1).getDescription());
    141142    }
    142143
Note: See TracChangeset for help on using the changeset viewer.