Ignore:
Timestamp:
2020-10-28T20:41:00+01:00 (3 years ago)
Author:
Don-vip
Message:

see #16567 - upgrade almost all tests to JUnit 5, except those depending on WiremockRule

See https://github.com/tomakehurst/wiremock/issues/684

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/test/unit/org/openstreetmap/josm/command/AddPrimitivesCommandTest.java

    r17240 r17275  
    22package org.openstreetmap.josm.command;
    33
    4 import static org.junit.Assert.assertArrayEquals;
    5 import static org.junit.Assert.assertEquals;
    6 import static org.junit.Assert.assertSame;
    7 import static org.junit.Assert.assertTrue;
     4import static org.junit.jupiter.api.Assertions.assertArrayEquals;
     5import static org.junit.jupiter.api.Assertions.assertEquals;
     6import static org.junit.jupiter.api.Assertions.assertSame;
     7import static org.junit.jupiter.api.Assertions.assertTrue;
    88
    99import java.util.ArrayList;
     
    1212import java.util.List;
    1313
    14 import org.junit.Rule;
    15 import org.junit.Test;
     14import org.junit.jupiter.api.extension.RegisterExtension;
     15import org.junit.jupiter.api.Test;
    1616import org.openstreetmap.josm.TestUtils;
    1717import org.openstreetmap.josm.data.coor.LatLon;
     
    3434 * Unit tests of {@link AddPrimitivesCommand} class.
    3535 */
    36 public class AddPrimitivesCommandTest {
     36class AddPrimitivesCommandTest {
    3737
    3838    /**
    3939     * We need prefs for nodes.
    4040     */
    41     @Rule
     41    @RegisterExtension
    4242    @SuppressFBWarnings(value = "URF_UNREAD_PUBLIC_OR_PROTECTED_FIELD")
    4343    public JOSMTestRules test = new JOSMTestRules().preferences().i18n();
     
    4747     */
    4848    @Test
    49     public void testAdd() {
     49    void testAdd() {
    5050        DataSet ds = new DataSet();
    5151
     
    6161     */
    6262    @Test
    63     public void testAddSetSelection() {
     63    void testAddSetSelection() {
    6464        DataSet ds = new DataSet();
    6565
     
    7777     */
    7878    @Test
    79     public void testAddToLayer() {
     79    void testAddToLayer() {
    8080        DataSet ds1 = new DataSet();
    8181        DataSet ds2 = new DataSet();
     
    9595     */
    9696    @Test
    97     public void testAddIgnoresExisting() {
     97    void testAddIgnoresExisting() {
    9898        DataSet ds = new DataSet();
    9999
     
    114114     */
    115115    @Test
    116     public void testDescription() {
     116    void testDescription() {
    117117        DataSet ds = new DataSet();
    118118
     
    138138     */
    139139    @Test
    140     public void testUndo() {
     140    void testUndo() {
    141141        DataSet ds = new DataSet();
    142142
     
    172172     */
    173173    @Test
    174     public void testUndoIgnoresExisting() {
     174    void testUndoIgnoresExisting() {
    175175        DataSet ds = new DataSet();
    176176
     
    208208     */
    209209    @Test
    210     public void testUndoIgnoresExistingAsDeleted() {
     210    void testUndoIgnoresExistingAsDeleted() {
    211211        DataSet ds = new DataSet();
    212212
     
    243243     */
    244244    @Test
    245     public void testUndoIgnoresExistingSameUniqueIdDifferentType() {
     245    void testUndoIgnoresExistingSameUniqueIdDifferentType() {
    246246        DataSet ds = new DataSet();
    247247
     
    288288     */
    289289    @Test
    290     public void testParticipatingPrimitives() {
     290    void testParticipatingPrimitives() {
    291291        DataSet ds = new DataSet();
    292292
     
    308308     */
    309309    @Test
    310     public void testFillModifiedData() {
     310    void testFillModifiedData() {
    311311        ArrayList<OsmPrimitive> modified = new ArrayList<>();
    312312        ArrayList<OsmPrimitive> deleted = new ArrayList<>();
     
    364364     */
    365365    @Test
    366     public void testEqualsContract() {
     366    void testEqualsContract() {
    367367        TestUtils.assumeWorkingEqualsVerifier();
    368368        EqualsVerifier.forClass(AddPrimitivesCommand.class).usingGetClass()
Note: See TracChangeset for help on using the changeset viewer.