Changeset 17275 in josm for trunk/test/unit/org/openstreetmap/josm/command/RemoveNodesCommandTest.java
- Timestamp:
- 2020-10-28T20:41:00+01:00 (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/test/unit/org/openstreetmap/josm/command/RemoveNodesCommandTest.java
r15013 r17275 2 2 package org.openstreetmap.josm.command; 3 3 4 import static org.junit. Assert.assertArrayEquals;5 import static org.junit. Assert.assertFalse;6 import static org.junit. Assert.assertTrue;4 import static org.junit.jupiter.api.Assertions.assertArrayEquals; 5 import static org.junit.jupiter.api.Assertions.assertFalse; 6 import static org.junit.jupiter.api.Assertions.assertTrue; 7 7 8 8 import java.util.ArrayList; 9 9 import java.util.Collections; 10 10 11 import org.junit. Before;12 import org.junit. Rule;13 import org.junit. Test;11 import org.junit.jupiter.api.BeforeEach; 12 import org.junit.jupiter.api.Test; 13 import org.junit.jupiter.api.extension.RegisterExtension; 14 14 import org.openstreetmap.josm.TestUtils; 15 15 import org.openstreetmap.josm.command.CommandTest.CommandTestDataWithRelation; … … 28 28 * Unit tests of {@link RemoveNodesCommand} class. 29 29 */ 30 publicclass RemoveNodesCommandTest {30 class RemoveNodesCommandTest { 31 31 32 32 /** 33 33 * We need prefs for nodes. 34 34 */ 35 @R ule35 @RegisterExtension 36 36 @SuppressFBWarnings(value = "URF_UNREAD_PUBLIC_OR_PROTECTED_FIELD") 37 37 public JOSMTestRules test = new JOSMTestRules().preferences(); … … 41 41 * Set up the test data. 42 42 */ 43 @Before 43 @BeforeEach 44 44 public void createTestData() { 45 45 testData = new CommandTestDataWithRelation(); … … 50 50 */ 51 51 @Test 52 publicvoid testExecute() {52 void testExecute() { 53 53 RemoveNodesCommand command = new RemoveNodesCommand(testData.existingWay, 54 54 Collections.singleton(testData.existingNode)); … … 65 65 */ 66 66 @Test 67 publicvoid testUndo() {67 void testUndo() { 68 68 RemoveNodesCommand command = new RemoveNodesCommand(testData.existingWay, 69 69 Collections.singleton(testData.existingNode)); … … 87 87 */ 88 88 @Test 89 publicvoid testFillModifiedData() {89 void testFillModifiedData() { 90 90 ArrayList<OsmPrimitive> modified = new ArrayList<>(); 91 91 ArrayList<OsmPrimitive> deleted = new ArrayList<>(); … … 103 103 */ 104 104 @Test 105 publicvoid testGetParticipatingPrimitives() {105 void testGetParticipatingPrimitives() { 106 106 RemoveNodesCommand command = new RemoveNodesCommand(testData.existingWay, 107 107 Collections.singleton(testData.existingNode)); … … 114 114 */ 115 115 @Test 116 publicvoid testDescription() {116 void testDescription() { 117 117 assertTrue(new RemoveNodesCommand(testData.existingWay, Collections.singleton(testData.existingNode)) 118 118 .getDescriptionText().matches("Removed nodes from .*")); … … 123 123 */ 124 124 @Test 125 publicvoid testEqualsContract() {125 void testEqualsContract() { 126 126 TestUtils.assumeWorkingEqualsVerifier(); 127 127 EqualsVerifier.forClass(RemoveNodesCommand.class).usingGetClass()
Note:
See TracChangeset
for help on using the changeset viewer.
